Dynadot Aftermarket: discover domain gems worth investing in. Visit our aftermarket.

HELP!! Dreamweaver expert needed! (Forms)

SpaceshipSpaceship
SpaceshipSpaceship
Namecheap AuctionsNamecheap Auctions
Watch
Impact
0
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
 
0
Close
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
What are you coding it in? VBScript, javacript, php..?
 
0
Close
Im just doing it in Dreamweaver MX....

Inserting a form.......
 
0
Close
I can make up a code for you if you want.

With which language did you program that form.?
 
0
Close
I could code you a PHP mail form for a small fee ... PM sent!
 
0
Close
Ill do you a PHP forum if Will7 dont do it :)
 
0
Close
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.
 
0
Close
That's all very well should he know how to use PHP, if not, then he's best of getting someone to do it for him ;)
 
0
Close
PHP isn't hard. I bet there are many sites about PHP forms on Google
 
0
Close
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 = "[email protected]";

// 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("^[[email protected]]+$", $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>

it should work, just change the variables to what you want
 
Last edited:
0
Close
There are tutorials, you can do this via CGI.
 
0
Close
Matt's formmail script is a good one and its relatively easy to set up
 
0
Close
I can easy create one, i just don;t seem 2 be able to link it to email address
 
0
Close
the one I provided does the linking for you
 
0
Close
0
Close
DomainEasy: white label portfolios are live. Enable yours.

We're social

Escrow.com
Spaceship
Domain Recover
CryptoExchange.com

NamePros updates

Search: choose where to search from the All tab
Open the search at the top of any page. On the All tab, the list next to the search box lets you choose where to search: everything, all...
AIVikings
Catchy
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back