hi all, i need help please, i know html, and thats about it, i know abit about forms also, but what i would like help on is this, <td width="565" align="center" valign="top"><table width="200" align="center">
<tr>
<td><form method="post" action="mailto:Customersupport@graf-x-designs.net" enctype="text/plain">
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="bottom" ><label for="q10" class="style5">Name</label>
</td>
<td valign="bottom"><input type="text" size="20" name="q10_Name" id="q10" />
</td>
</tr>
</table>
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="bottom" ><label for="q11"><span class="style5">Email address</span></label>
</td>
<td valign="bottom"><input type="text" size="20" name="q11_Emailaddress" id="q11" />
</td>
</tr>
</table>
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="bottom" ><label for="label"><span class="style5">Contact Number </span></label>
</td>
<td valign="bottom"><input type="text" size="20" name="q12_contact number" id="label" />
</td>
</tr>
</table>
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="bottom" ><label for="q16"><span class="style5">Who is your question for </span></label>
</td>
<td valign="bottom"><select name="q16_whoisyourquestionto" id="q16">
<option></option>
<option>QUOTES </option>
<option>COMPLAINTS </option>
<option>GENERAL ENQ </option>
<option>WEB MASTER</option>
</select>
</td>
</tr>
</table>
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="bottom" ><label for="q16"><span class="style5">Choose your colour/if not on list tell us which you would like below </span></label>
</td>
<td valign="middle"><p>
<select name="q16_4gloss" id="q16">
<option>4 Series Gloss</option>
<option>M4-200 </option>
<option>M4-205 </option>
<option>M4-220 </option>
<option>M4-221 </option>
<option>M4-224 </option>
<option>M4-210 </option>
<option>M4-230 </option>
<option>M4-232 </option>
<option>M4-235 </option>
<option>M4-237 </option>
<option>M4-233 </option>
<option>M4-240 </option>
<option>M4-247 </option>
<option>M4-246 </option>
<option>M4-243 </option>
<option>M4-245 </option>
<option>M4-277 </option>
<option>M4-250 </option>
<option>M4-258 </option>
<option>M4-252 </option>
<option>M4-254 </option>
<option>M4-255 </option>
<option>M4-275 </option>
<option>M4-278 </option>
<option>M4-259 </option>
<option>M4-261 </option>
<option>M4-269 </option>
<option>M4-263 </option>
<option>M4-268 </option>
<option>M4-267 </option>
<option>M4-264 </option>
<option>M4-273 </option>
<option>M4-265 </option>
<option>M4-282 </option>
<option>M4-283 </option>
<option>M4-272 </option>
<option>M4-270 </option>
<option>M4-271 </option>
<option>M4-290 </option>
<option>M4-291 </option>
<option>M4-292 </option>
</select>
<select name="q17_4matte" id="q16">
<option>4 Series Matte</option>
<option>M4-301 </option>
<option>M4-324 </option>
<option>M4-311 </option>
<option>M4-320 </option>
<option>M4-330 </option>
<option>M4-332 </option>
<option>M4-334 </option>
<option>M4-333 </option>
<option>M4-340 </option>
<option>M4-341 </option>
<option>M4-343 </option>
<option>M4-345 </option>
<option>M4-358 </option>
<option>M4-352 </option>
<option>M4-353 </option>
<option>M4-354 </option>
<option>M4-355 </option>
<option>M4-359 </option>
<option>M4-360 </option>
<option>M4-361 </option>
<option>M4-362 </option>
<option>M4-368 </option>
<option>M4-364 </option>
<option>M4-366 </option>
<option>M4-381 </option>
<option>M4-382 </option>
<option>M4-383 </option>
<option>M4-370 </option>
<option>M4-372 </option>
<option>M4-390 </option>
<option>M4-391 </option>
</select>
<select name="q18_series7" id="q16">
<option>Series 7</option>
<option>M7-100 </option>
<option>M7-101M </option>
<option>M7-105 </option>
<option>M7-122 </option>
<option>M7-121 </option>
<option>M7-123 </option>
<option>M7-124 </option>
<option>M7-125 </option>
<option>M7-110 </option>
<option>M7-111M </option>
<option>M7-130 </option>
<option>M7-136 </option>
<option>M7-131 </option>
<option>M7-132 </option>
<option>M7-137 </option>
<option>M7-134 </option>
<option>M7-133 </option>
<option>M7-171 </option>
<option>M7-140 </option>
<option>M7-144 </option>
<option>M7-141 </option>
<option>M7-142 </option>
<option>M7-143 </option>
<option>M7-148 </option>
<option>M7-145 </option>
<option>M7-177 </option>
<option>M7-150 </option>
<option>M7-151 </option>
<option>M7-152 </option>
<option>M7-153 </option>
<option>M7-154 </option>
<option>M7-155 </option>
<option>M7-158 </option>
<option>M7-178 </option>
<option>M7-156 </option>
<option>M7-157 </option>
<option>M7-160 </option>
<option>M7-161 </option>
<option>M7-162 </option>
<option>M7-163 </option>
<option>M7-164 </option>
<option>M7-173 </option>
<option>M7-165 </option>
<option>M7-166 </option>
<option>M7-182 </option>
<option>M7-183 </option>
<option>M7-184 </option>
<option>M7-172 </option>
<option>M7-170 </option>
<option>M7-191 </option>
<option>M7-190 </option>
<option>M7-192 </option>
</select>
<select name="q19_tseries" id="q16">
<option>T-Series</option>
<option>MT-620 </option>
<option>MT-621 </option>
<option>MT-630 </option>
<option>MT-635 </option>
<option>MT-633 </option>
<option>MT-636 </option>
<option>MT-640 </option>
<option>MT-641 </option>
<option>MT-642 </option>
<option>MT-643 </option>
<option>MT-647 </option>
<option>MT-645 </option>
<option>MT-649 </option>
<option>MT-600 </option>
<option>MT-610 </option>
<option>MT-651 </option>
<option>MT-676 </option>
<option>MT-653 </option>
<option>MT-654 </option>
<option>MT-659 </option>
<option>MT-675 </option>
<option>MT-677 </option>
<option>MT-670 </option>
<option>MT-672 </option>
<option>MT-660 </option>
<option>MT-665 </option>
<option>MT-666 </option>
<option>MT-667 </option>
<option>MT-668 </option>
<option>MT-669 </option>
<option>MT-678 </option>
<option>MT-679 </option>
<option>MT-683 </option>
<option>MT-684 </option>
<option>MT-685 </option>
</select>
<select name="q20_banner" id="q16">
<option>Flex</option>
<option>MF-900 </option>
<option>MF-920 </option>
<option>MF-924 </option>
<option>MF-910 </option>
<option>MF-930 </option>
<option>MF-931 </option>
<option>MF-932 </option>
<option>MF-933 </option>
<option>MF-942 </option>
<option>MF-943 </option>
<option>MF-945 </option>
<option>MF-983 </option>
<option>MF-957 </option>
<option>MF-955 </option>
<option>MF-954 </option>
<option>MF-951 </option>
<option>MF-962 </option>
<option>MF-967 </option>
<option>MF-991 </option>
<option>MF-990 </option>
</select>
</p></td>
</tr>
</table>
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="top"><label for="q14" class="style5"><span class="style4 style2">Your order/Questions</span></label>
</td>
<td valign="bottom"><textarea wrap="soft" cols="30" rows="3" name="q14_YourorderQuestions" id="q14"></textarea>
</td>
</tr>
</table>
<table width="520" align="center" cellpadding="5" cellspacing="0">
<tr valign="bottom">
<td width="150" valign="bottom" ></td>
<td valign="bottom"><a href="mainframe.html" target="_self">
<input type="hidden" name="redirect" value="http://www.graf-x-designs.net/index.html" />
<input name="submit" type="submit" value="Send" />
<input name="reset" type="reset" value="Clear" />
</a></td>
</tr>
</table>
</form></td>
</tr>
</table>
<table width="510" height="61">
<tr>
<td><table height="55" width="504" align="center" border="0">
<tbody>
<tr>
<td><div align="center" class="style5">If you press submit and the page does not change, dont worry, this is a technical fault but the messege will still be sent. </div></td>
</tr>
</tbody>
</table></td>
</tr>
</table>
<p class="style5">&nbsp;</p></td>

Thats the code for my form, and i would love it to redirect when someone presses submit, but it will not, what am i missing, or doing wrong, its making my brain hurt, (what there is of it) i would love it if some here could help me, if anyone helps me to get it sorted i will be eternally grateful:cheesy:

Write a CGI script to perform the mailing operation from your server, and then redirect the page at the end of the script.

mailto: isn't totally reliable anyway. I don't use a default mail client on any computer except at work; and your code relies on me (as a user) having one enabled and letting webpages acess it.

But, if you really want use mailto as an action, and can't use CGI for any reason, try adding this to the form tag attributes:

<form method="post" action="mailto:Customersupport@graf-x-designs.net" 
enctype="text/plain" [B]onsubmit="window.setTimeout(function(){window.location='http://redirect here'},20); return true;"[/B]>

But, if you really want use mailto as an action, and can't use CGI for any reason, try adding this to the form tag attributes:

<form method="post" action="mailto:Customersupport@graf-x-designs.net" 
enctype="text/plain" [B]onsubmit="window.setTimeout(function(){window.location='http://redirect here'},20); return true;"[/B]>

Hi Matt, Thanks for the speedy reply, after reading what you said, you obviously know what your talking about, and i dont. The timeout redirect i feel will have its drawbacks as if you dont fill it in quick enough it will change, but the other problem is cgi, how would i achieve the form in cgi, as i dont know cgi, if you could send me to anywhere that would teach me the code on the net, it would be very very helpful. P.s I have just loaded up my site in FF and it didnt send me an email, i see what you meen about the codes other problem.

if you dont fill it in quick enough it will change

hehe... nah.. it wil only start timing out when the submit button is pressed... 20 timeout ticks is too short to do anything except blink... the reason for using timeout instead of setting the window.location first is that the form might not submit atall if the browser changes location before the form has been submitted.

CGI is quite a general term... it means Common Gateway Interface, and gramatically, the way I used it in that post was wrong.

CGI script is a better term; in the-most-basic terms, a CGI script is a program that you can access as if it were a webpage.

I think you can probably write CGI script in any programming language that supports character input and output... but the most common CGI languages today are PHP, ASP, and maybe Perl.

The kind of CGI script you'd want to write for the mailing purpose would need to accept the input sent to it from your HTML form (that's going in through the "Common Gateway"); perform a server-side mailing operation based on the input recieved, and then send Redirect 301 and Location headers to send the user's browser to the next page (that's going out of the 'Common Gateway')

So, I'd say you need a language that provides mail support 'automatically'; I'd advise PHP (only because it's very widely supported on different server platforms). Personally, Perl is always my first choice..

If you want to learn PHP and CGI at the same time, perhaps this will be helpful:
http://www.communitymx.com/content/article.cfm?page=2&cid=D5084

When you know the basics, finding out how to send mail from your server is the next part.. This will differ vastly depending on who you buy your hosting from and how much you pay. Some hosts offer extremely restricted script-based emailing to prevent abuse.. Other hosts offer totally unrestricted scripting but very little user support... the best hosts for non-experts are usually in the middle somewhere.

Once you know whether you can send email, and if theres any special rules you need to adhere to; languages like PHP and Perl make the rest simple(r). Generally, they'll provide a function or module that you can use (something like send_mail(where,to,from,etc) ). At worst, there'll be lots of user guides/walkthroughs/code samples on the Internet that can adapt for your purposes.

When you access a CGI script, the server where you host your website runs the script; and the mail function that you've used will cause the server to actively send the mail using its own internal programs, rather than prompt the user to send mail through their desktop mail client. That means (providing your script is written correctly) your script is always going to work, regardless of how or who accesses your page.

The last bit would be redirecting the user. If you get that far, you'll be able to find out how to do that =)

I hope that's been a bit helpful..

Well thank you very much, you have helped alot actually, thank you for taking the time to help me and type in a hell of alot advice, your time is greatly apprieciated, i will let you know how i get on, and when i am up and running properly, i will let ya know so you can get some discount on the products we will be selling. cheers

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.