Click to See Complete Forum and Search --> : Form doesn't work properly


fnunpres
11-21-2003, 09:53 AM
The following is the form I set up for the website, but it doesn't send me the information properly. No comments come through, for example. What is wrong?

<CENTER>
<IMG SRC="contacthdr.jpg" WIDTH=525 HEIGHT=80 BORDER=0 ALT="First National University Contacts">
</CENTER>
<P>
<br>
<!--#include virtual="/csIncludes/CSIncludes.cgi?id=Babilfish"-->
<br>
<BR>

<body>


<fieldset>
<legend>
Contact Information:
</legend>
<form action="MAILTO:info@fnun.edu" method="post" enctype="text/plain">
<pre>

First Name: <input type="text" name="firstname"size="20"> Last Name: <input type="text" name="lastname"size="20"> Profession: <select name="Profession">
<option value="M.D.">M.D.
<option value="D.O.">D.O.
<option value="Nurse">Nurse
<option value="E.M.T.">E.M.T.
<option value="Paramedic">Paramedic
<option value="Other" selected>Other
</select>
<br>
EMail: <input type="text" name="email"size="20"> Address: <input type="text" name="mail"size="20">
<br>
City: <input type="text" name="city"size="20"> State: <input type="text" name="state"size="20"> Zip Code: <input type="text" name="zipcode"size="20">
<br>
</pre>
Comment or Question:<BR>
<center>
<textarea rows="10" cols="50">
</textarea>
</center>
<br><br>

<center>
<input type="submit" value="Send"> <input type="reset" value="Reset">
</center>

</form>
</fieldset>

toicontien
11-21-2003, 10:49 AM
Do you have SSI enabled on the web server? And second of all, the file extension for the HTML page matters. SSI HTML pages should end in .shtm or .shtml.

The other thing to look for is to make sure the file path to the included file is correct. Having /csIncludes/CSIncludes.cgi?id=Babilfish will cause browsers to look at the web site root, or web site home directory, and then csIncludes/CSIncludes.cgi (if you already know this, my apologies). If your web server is a Unix server, file names and paths are case sensitive. Also make sure you have the proper permissions set for the CGI file. On Unix/Linux servers, it should be something like RWXR-XR-X.

CyCo
11-21-2003, 10:54 AM
...mailto forms are fickle at best, but if you're not getting "Comments", try naming the textarea to name="comments" or something similar...this will associate a name/value pair for the query string, thus sending the info along with the other inputs

I'm assuming the other inputs are working??
...also, to avoid confusion, you should separate the name of your inputs and size with a space

<input type="text" name="zipcode"size="20">
with space:
<input type="text" name="zipcode" size="20">

fnunpres
11-21-2003, 12:22 PM
Thanks toicontien

Yes, everything is set up for serversides and cgi scripts and permissions are there for the scripts.

fnunpres
11-21-2003, 12:30 PM
Originally posted by CyCo
...mailto forms are fickle at best, but if you're not getting "Comments", try naming the textarea to name="comments" or something similar...this will associate a name/value pair for the query string, thus sending the info along with the other inputs

I'm assuming the other inputs are working??
...also, to avoid confusion, you should separate the name of your inputs and size with a space

<input type="text" name="zipcode"size="20">
with space:
<input type="text" name="zipcode" size="20">

I thought it was sending the form, but it isn't.

It sends to the email program, but there is nothing in the subject or message.

I made the changes you mentioned, I think. Any other ideas on why this isn't working?


<fieldset>
<legend>
Contact Information:
</legend>
<form action="MAILTO:info@fnun.edu" method="post" enctype="text/plain">
<pre>

First Name: <input type="text" name="firstname" size="20"> Last Name: <input type="text" name="lastname" size="20"> Profession: <select name="Profession">
<option value="M.D.">M.D.
<option value="D.O.">D.O.
<option value="Nurse">Nurse
<option value="E.M.T.">E.M.T.
<option value="Paramedic">Paramedic
<option value="Other" selected>Other
</select>
<br>
EMail: <input type="text" name="email" size="20"> Address: <input type="text" name="mail" size="20">
<br>
City: <input type="text" name="city" size="20"> State: <input type="text" name="state" size="20"> Zip Code: <input type="text" name="zipcode" size="20">
<br>
</pre>
<legend>Comment or Question:</legend><input type="text" name="comment"><BR>
<center>
<textarea rows="10" cols="50">
</textarea>
</center>
<br><br>

<center>
<input type="submit" value="Send"> <input type="reset" value="Reset">
</center>

</form>
</fieldset>

ray326
11-21-2003, 01:29 PM
<legend>Comment or Question:</legend><input type="text" name="comment"><BR>
<center>
<textarea rows="10" cols="50">
</textarea>
</center>

Should be:

<legend>Comment or Question:</legend><BR>
<center>
<textarea name="comment" rows="10" cols="50">
</textarea>
</center>

fnunpres
11-21-2003, 01:54 PM
Thanks Ray!

Made the changes, and it displays better, but it still doesn't send the text to the email - just the address.

CyCo
11-21-2003, 02:01 PM
I don't quite understand what problem you are experiencing, but I just took your form...put it on my site (changed the address to mine) and tried it out twice with perfect results...
using Outlook Express...

below is the result I received...

Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: 7bit


firstname=Fred
lastname=Barnes
Profession=D.O.
email=me@overhere.net
mail=8888 East High
city=Simpson
state=Nevada
zipcode=98765
comment=...A subject...?
subject=Form Submission


*Note, I added a hidden field named "subject" and it's corresponding value "Form Submission", testing to see if it would in fact replace the Default Subject line that the mail client uses, but that doesn't happen...

fnunpres
11-21-2003, 03:03 PM
Hello CyCo:

It may just be my Pegasus email that it isn't working with then, as it works with your Outlook.

Do me a favor, go to www.fnun.edu/contact.html and send me a form from CyCo.

THANKS Y'all!

ray326
11-21-2003, 11:25 PM
Originally posted by fnunpres
It may just be my Pegasus email that it isn't working with then, as it works with your Outlook.

I'd suspect your browser before your email client. After all that's what is processing the form. I'm running Mozilla.

fnunpres
11-25-2003, 11:13 AM
Thanks y'all. It works now. Appreciate the advice.