| | |||||
| ||||||||
| Web Design Discussion Discussion of web design techniques, advice, browser issues, software, design firms. |
![]() |
| | LinkBack | Thread Tools |
| | THREAD STARTER #1 (permalink) |
| New Member Join Date: Oct 2005
Posts: 5
![]() | HELP!! Dreamweaver expert needed! (Forms) Hi i was wondering if anyone could help me. My sister has a small business, i've set up a website for her and now i'm trying to set up a form so that people can submit a query to her e-mail address via a form I have got this far (see link below) however i need to know how to set the properties so that it is sent to the relevant Email address! Any help would be greatly appreciated Thanks http://homepage.ntlworld.com/chris.haran/UsingForms.htm |
| |
| | #7 (permalink) |
| Senior Member Join Date: Jul 2005 Location: England
Posts: 4,570
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | Or. . You could just google PHP form code or somethng, i would think there are lots of free scripts you could edit to your needs.
__________________ If you always do what you've always done, you'll always have what you've always had. |
| |
| | #10 (permalink) |
| Senior Member Join Date: May 2005
Posts: 1,538
![]() ![]() | use this Code: <!-- Copyright © 2002 Kali (http://www.xentrik.net) -->
<html><head>
<title>Bum Records - Advertisement Form</title>
<?php
// COPYRIGHT/LIABILITY NOTICE
// Copyright © 2002 Kali (http://www.xentrik.net)
// Last modified 04/05/2004
// Kali's Contact Form may be used and modified free of charge as long as this
// copyright notice and the comments above remain intact. By using this code
// you agree to indemnify Kali from any liability that might arise from its use.
// Selling the code for this program without prior written consent is not permitted.
// Permission must be obtained before redistributing this software. In all cases the
// copyright and header information must remain intact.
// MODIFY THE FOLLOWING SECTION
// your name
$recipientname = "Def 1";
// your email
$recipientemail = "bum0016@hotmail.com";
// subject of the email sent to you
$subject = "Online-Form Response for $recipientname";
// send an autoresponse to the user?
$autoresponse = "yes";
// subject of autoresponse
$autosubject = "Thank you for your mail!";
// autoresponse message
$automessage = "This is an auto response to let you know that we've successfully received your email sent through our email form. Thanks! We'll get back to you shortly.";
// thankyou displayed after the user clicks "submit"
$thanks = "Thank you for contacting us.<br>We will get back to you as soon as possible.<br>";
// END OF NECESSARY MODIFICATIONS
?>
<style type="text/css"><!--
td,body,input,textarea {
font-size:12px;
font-family:Verdana,Arial,Helvetica,sans-serif;
color:#000000}
--></style>
</head>
<body>
<table width="100%" height="100%"><tr>
<td valign="top"><font face="Verdana,Arial,Helvetica" size="2">
<?php
if($_POST['submitform']) {
$Name = $HTTP_POST_VARS['Name'];
$Email = $HTTP_POST_VARS['Email'];
$Comments = $HTTP_POST_VARS['Comments'];
// check required fields
$dcheck = explode(",",$require);
while(list($check) = each($dcheck)) {
if(!$$dcheck[$check]) {
$error .= "Missing $dcheck[$check]<br>";
}
}
// check email address
if ((!ereg(".+\@.+\..+", $Email)) || (!ereg("^[a-zA-Z0-9_@.-]+$", $Email))){
$error .= "Invalid email address<br>";}
// display errors
if($error) {
?>
<b>Error</b><br>
<?php echo $error; ?><br>
<a href="#" onClick="history.go(-1)">try again</a>
<?php
}
else
{
$browser = $HTTP_USER_AGENT;
$ip = $REMOTE_ADDR;
// format message
$message = "Online-Form Response for $recipientname:
Name: $Name
Email: $Email
Comments: $Comments
-----------------------------
Browser: $browser
User IP: $ip";
// send mail and print success message
mail($recipientemail,"$subject","$message","From: $Name <$Email>");
if($autoresponse == "yes") {
$autosubject = stripslashes($autosubject);
$automessage = stripslashes($automessage);
mail($Email,"$autosubject","$automessage","From: $recipientname <$recipientemail>");
}
echo "$thanks";
}
}
else {
?>
<form name="contactform" action="<?php echo $PHP_SELF; ?>" method="post">
<input type="hidden" name="require" value="Name,Email,Comments">
<table><tr>
<td colspan="2" align="center"><b>Contact Me!</b><p></td>
</tr><tr>
<td valign="top" align="right">Name:</td>
<td valign="top"><input name="Name" size="25"></td>
</tr><tr>
<td valign="top" align="right">E-mail:</td>
<td valign="top"><input name="Email" size="25"></td>
</tr><tr>
<td valign="top" align="right">Comments:</td>
<td valign="top"><textarea name="Comments" rows="5" cols="35"></textarea></td>
</tr><tr>
<td colspan="2" align="center"><input type="submit" value="Submit" name="submitform">
<input type="reset" value="Reset" name="reset"></td>
</tr></table>
<br>
</form>
<?php } ?>
</font><p></td>
</tr><tr>
<td valign="bottom"><font face="Verdana" size="1">Mailform Copyright © 2002 <a href="http://www.xentrik.net/">Kali's Web Shoppe</a>.</font></td>
</tr></table>
</body>
</html>
__________________ Did you try my toolbar? Works in Firefox and IE! http://www.bumrecords.net - Fun Games, Music, Discussion, And Much More! upload² •Pick the Web Hosting Company most NamePros Members Use Pick Chronichosting!•
Last edited by def1; 10-08-2005 at 12:38 PM.
|
| |
| | #14 (permalink) |
| Senior Member Join Date: May 2005
Posts: 1,538
![]() ![]() | the one I provided does the linking for you
__________________ Did you try my toolbar? Works in Firefox and IE! http://www.bumrecords.net - Fun Games, Music, Discussion, And Much More! upload² •Pick the Web Hosting Company most NamePros Members Use Pick Chronichosting!• |
| |
| | #15 (permalink) |
| Account Closed Join Date: Sep 2005
Posts: 141
![]() | Many of such free scripts available, you can get some at the following link: http://scriptmenu.com/browse-form_processors-524-1.html :> |
| |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Vbullitin Expert Needed Urgent... | tls2005 | Programming | 2 | 05-18-2005 05:21 PM |
| PLEASE READ: TOS/AUP/PP and more than 100 additional legal forms - One great price! | zerdomains | Web Development Wanted | 0 | 04-27-2005 04:02 PM |
| form filling script needed | Guzey | Web Design Discussion | 0 | 04-10-2005 11:05 AM |
| Forms | innovative | Web Design Discussion | 6 | 05-04-2004 02:40 AM |