Question about Forms

liunx

Guest
I am making a form, but instead of just sending it brings up outlook express. how do i keep it from doing this?<!--content-->Use a server side language to submit your emails instead of an html based email form because it depends on a mail client. What server side language does your host support?<!--content-->im not sure exactly.... i know it supports PHP (obviously :P ) but im not sure about the rest. Isnt there a way i can do it with php<!--content-->im not sure... i now it supports php. you can do it with that right?<!--content-->Sure thing, and here's the script to do it... <!-- m --><a class="postlink" href="http://www.webdevfaqs.com/php.php#mailer">http://www.webdevfaqs.com/php.php#mailer</a><!-- m --><!--content-->i really hope you guys dont think im a complete moron... but I'm basically teaching myself how to do this and i really appreicate the help <br />
<br />
Anyway... i tried it out and now when i press submit it brings up a window asking me to save the php file i made for the form. this is exactly what i did :<br />
<br />
1. I made the php file and copied the code in exactly as it was in the site you sent me and i named it mailer.php<br />
<br />
2. I edited the top part of the php code like it asked like this:<br />
<br />
$to = "[email protected]"; #set address to send form to <br />
$subject = "Member of the Month"; #set the subject line <br />
$headers = "Member of the Month"; #set the from address, or any other headers <br />
$forward = 0; # redirect? 1 : yes || 0 : no <br />
$location = "thankyou.htm"; #set page to redirect to, if 1 is above <br />
<br />
I didnt do anything with the thankyou.htm... i guess i figured i could do it later, I just want the submit part to work for now<br />
<br />
3. I entered the form script in my page as follows : <br />
<br />
<form action='mailer.php' method='post'><br />
<table width="408" border="0"><br />
<tr> <br />
<td width="238"><font color="#5ABDFF"><b>Your Neopets <br />
Username :</b></font></td><br />
<td width="160"><input type='text' name='textfield3'></td><br />
</tr><br />
<tr> <br />
<td><font color="#5ABDFF"><b>Nominee's Neopets Username:</b></font></td><br />
<td><input type='text' name='textfield22'></td><br />
</tr><br />
<tr> </tr><br />
</table><br />
<br><br />
<input type='submit' name='submit' value='Submit Form'><br />
</form><br />
<br />
what am i doing wrong? thanks<!--content-->It would appear that your server does not support PHP. Try a simple test:<br />
<br />
test.php<br />
<?PHP<br />
echo "I have PHP";<br />
?>What does that give you?<!--content-->If they do not support php then you need to fig around in your hosts faq and try to find out what they support, if you can't find anything contact them. You really do need to know what your host offers.<!--content-->ok... i dont know what i did but i t works now :) thanks for your support! you guys were a big help<!--content-->
 
Back
Top