Click to See Complete Forum and Search --> : Forms Submit to Email not working


rupda27
06-10-2003, 02:33 PM
FORMS question:

When a user expands or reduces their browser, making all the text larger or smaller, I've noticed that it breaks up my tables now that I have a form field in there. The form filed is nested in a table that has the width set, and yet the table still breaks, anyone knows how to avoid this??

Example:

http://www.studiopresence.com/clients/anonymous/


CGI question:

In the same proceeding page (link above), I also want to have users send emails to me, but I'm having trouble getting it to work. Here's my attempt:


<TD align="center" WIDTH=100 bgcolor="#EEEEEE">
<form action="mailto:limors@mindspring.com" method="post" enctype="text/plain" name="email" id="email">
<input name="email" type="text" id="email" size="13" maxlength="50">
</form>
</TD>
<TD> <IMG SRC="../images/fill.10.gif" WIDTH=7 HEIGHT=19 ALT=""></TD>
</TR>
<TR>
<TD COLSPAN=3> <IMG SRC="../images/fill.19.gif" WIDTH=113 HEIGHT=5 ALT=""></TD>
</TR>
<TR>
<TD> <IMG SRC="../images/fill.11.gif" WIDTH=6 HEIGHT=23 ALT=""></TD>
<TD align="right" WIDTH=100 bgcolor="#EEEEEE"><form action="" method="post" name="email" id="email">
<input type="submit" name="Submit" value="Submit">
</form> </TD>


Forgive me, I'm not very verse on the technical side, so I'm sure some of this code could be written better. I do know that my server has a CGI bin in it.


Lastly, after the user hits "send" I get this error:

Method Not Allowed
The requested method POST is not allowed for the URL /clients/anonymous/index.htm.

Thanks in advance!
Rupda27

Charles
06-10-2003, 03:06 PM
Both of your problems are biong caused by your using TABLEs for layout which you ought not to be doing. Control your layout with CSS and all should be well.

rupda27
06-10-2003, 06:53 PM
>

Hmm, well, I guess I'll start looking for some CSS formating that would assist me in setting the structure to my forms. Any suggestions?

I'm still stuck on getting the data sent to me in plain/text via email?
If this is the code on the text box:

<form action="mailto:limors@mindspring.com" method="post" enctype="text/plain" name="email" id="email">

Then what is the code supposed to be on the related Submit button?

Thanks in advance,
Rupda27:

Charles
06-10-2003, 07:42 PM
The submit button has to be contained by the form it is going to submit.

<form action="mailto:limors@mindspring.com" method="post" enctype="text/plain" name="email" id="email">
<input name="email" type="text" id="email" size="13" maxlength="50">
<input type="submit">
</form>

rupda27
06-17-2003, 07:56 PM
It still doesn't work. Any other advice????

I've been at this Sign Up form for over 8 hours and still seem to mess it up (http://www.studiopresence.com/clients/anonymous) In my case, I'm only asking for the user to enter their email address and then have that data passed back to me in a plain text format. I downloaded FormMail.pl and tried to follow the instructions, but somehow, I'm completely incompetent or I've just lost patients with the darn thing, probably both.

Question, once I get this thing working and the user hits "send" can I have the user go to another html page to thank them for signing up?

Thanks for your time!!!

Jona
06-18-2003, 12:41 AM
Originally posted by rupda27
It still doesn't work. Any other advice????

As Charles said, post a link to the page that has this form; or post the code you're using. Charles's code works fine.

Originally posted by rupda27
I downloaded FormMail.pl and tried to follow the instructions, but somehow, I'm completely incompetent or I've just lost patients with the darn thing, probably both.

I've fooled around with CGI lately, and created a script that will process a form, print the results on the next page (the "thank you page") and send an email to whatever email address I'd like. The script also includes form validation. And it is much smaller than the formMail.pl script. In fact, the whole code is about 25 to 35 lines in all.

Originally posted by rupda27
Question, once I get this thing working and the user hits "send" can I have the user go to another html page to thank them for signing up?


As implied above, yes you can do this very easily.

Jona

zonegal
06-20-2003, 03:35 PM
In your FormMail.pl you need to change the code:

@allow_mail_to Enables you to specify the email address to which the form results are to be mailed. The value of this field should match that of the form's recipient address.
Syntax
@allow_mail_to = qw(limors@mindspring.com);


And in your html code:
//put the path to your FormMail.pl file in your server, I don't know where it's located, so I just assume it's in the cgi-bin
<form method="post" name="order" action="http://www.mindspring.com/cgi-bin/FormMail.pl">

//for the user to enter their email
<input type="text" name="youremail" value="YourEmail" > Your Email address?

//to send the user input to your email
<input type="hidden" name="recipient" value="limors@mindspring.com" >

//required user to input before they click on submit
<input type="hidden" name="required" value="youremail" >

//after clicking on submit, the user will be taken to the thank you page.. which you have to create
<input type="hidden" name="redirect" value="put your thankyou page path here" >

</form>

I hope this help! :)