HTML - Form Action Problems
Hey guys I am making a application form for my website and I have a few questions...
After the application is complete and they hit Submit I want a message to come up and say "Thank you for the application" Then it clears all the text boxes etc to default so they know that the application is complete. How do I get that happening? Also I want the application to go to my email however I do not want the application to open a email form, at the moment I have got Code: <form action="MAILTO:contact@xin-gaming.com" method="post" enctype="text/plain"> but that opens up an email form so that they send it as if it was an email which I don't want. I want it to send it to my email but without the applicant knowing that it's going to my email. Sorry for the confusion >< Thank you in advance Similar Tutorialshi i was wondering if anyone has any idea how i can add more then one form action to the same page? i have 2 in my page but they are conflicting with each other thanks... This is how i have it in my page: Code: <form name="form" method="post" action="login.php"> form action 1 my code here..... </form> <form name="form" method="post" action="index.php"> form action 2 my code here..... </form> I made a HTML Submittion, but everytime a user adds stuff, like their name, etc. it redirects to another page. Is it possible, to let the HTML Submisision, submit the details, without it going to a different page? Hi, Is there any way to have more than one action script in a form? Thanks in advance! Geetha ooh, its been a long time since i had to ask a question in here. i have a form that just wants to redirect to the home page, no matter what the action is. HTML Code: <form id="contactForm" method="post" action="index.phtml?file=contact.phtml" enctype="multipart/form-data"> <input class="input" name="contact_name" type="text" onfocus="if(this.value == 'Name:') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Name:' }" value="<?php echo (!empty($_POST['contact_name']) && $_POST['contact_name']) ? $_POST['contact_name'] : 'Name:'; ?>" /> <input class="input" name="contact_phone" type="text" onfocus="if(this.value == 'Phone:') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Phone:' }" value="<?php echo (!empty($_POST['contact_phone'])) ? $_POST['contact_phone']: 'Phone:'; ?>" /> <input class="input" name="contact_email" type="text" onfocus="if(this.value == 'E-Mail:') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'E-Mail:' }" value="<?php echo (!empty($_POST['contact_email'])) ? $_POST['contact_email']: 'E-Mail:'; ?>" /> <textarea name="contact_message" cols="1" rows="1" onfocus="if(this.value == 'Message:') { this.value = ''; }" onblur="if(this.value=='') this.value='Message:'" /><?php echo (!empty($_POST['contact_message'])) ? $_POST['contact_message'] : 'Message:'; ?></textarea> <a href="#" class="right link1" onclick="document.getElementById('contactForm').submit()">Send</a> <a href="#" class="right link1" onclick="document.getElementById('contactForm').reset()">Clear</a> <input name="ContactSubmit" type="hidden" /> </form> and its not submitting. i think i messed up the link submits, what url shoudl be in there, when i put in index.phtml?file=contact.phtml it stays on the page but doesnt process. also, is the enctype correct for this type of post? also my doc type is xhtml strict, but i am going to have to satisfy a couple errors as far as that is concerned as well, its complaining about Quote: document type does not allow element "input" here; missing one of "p", "h1", "h2", "h3", "h4", "h5", "h6", "div", "pre", "address", "fieldset", "ins", "del" start-tag when i change the action even to itself which is /contact.phtml it still redirects to the home page. i have to ask it, what obvious fundamental have i forgotton? EDIT, ok it must be in the link submits, when i delete the href tag out of it completely, it seems to be processing. i cant figure out why the # sign was in there, whats supposed to be there for a link submit? i trued a url and that didnt work right Hi, Is there any way to have more than one action script in a form? Regards, Geetha This maybe a dumb question. I form that I use for my mailing list. I am having trouble getting the cursor to display as a text cursor over the input section and a hand cursor over the "sign up" button. Ref: http://bigdogcattle.com Here is the html code: <div class="form_contents"> <label for="email">Join our Mailing List</label> <input type="text" name="email" /> <br/><br/> <input type="submit" value="Sign Up!"/> </div> Any ideas? Thanks, Jamie Can i assign a URL like index.php?page=result using the get method in a php form. Ex: HTML Code: <form action="?page=results" method="get"> <input type="submit" value="Submit"> </form> I''m making a form with three input bars. When the user presses "submit", the contents of the three inputs is put together in a string, which is then sent to a CGI program. Is there any way to add arbitrary text to that string - whether before or after the stuff gathered from the form's inputs - so that my CGI program can know which form called it? Hey guys. This is my coding, below, for a form on my site. It's just the default white color (and is too bright for my site's color scheme). Is there any way I can change the color to grey or something else?? THanks in advance!! <form action="http://www.xxx.com/xxx/xxx/xxx.php?group=2" method="post"> <div align="center" style="height:30px;"><font size="1px" color="999999" face="Arial"><b>enter your email address and your info will be emailed to you</b></font></div><div align="center" style="height:30px;"><input name="email" value=" " /></div><div align="center"><input type="image" src="buttons.jpg" size="25" value="Find password" /></div> </form> ok....i have a htm form that has fields that do a get to a aspx datagrid page. this is done in the action part of the form. i set in the form to target a new winodw but how can i have that new window open with no browser menu? i have googled and found ways to do this in the input onclick but either im setting it wrong or it will not work with the get action Code: <form name="Form1" method="get" action="../lookup/phydatagrid.aspx?tablename=physicians" onsubmit="return validateZIP(this.zipcode.value, this.radius.value, this.name)" target="_blank"> Hi All, I want to change the form action clicking on radio button. I have two radio button. the default action is a1.jsp if I click on update button If I click on second radio button I want to change the form action. I want to redirect to another file (change form action if possible) if I click on second radio button How can I do that ? Thanks please reply soon. Hi All, I want to change the form action clicking on radio button. I have two radio button. the default action is a1.jsp if I click on update button If I click on second radio button I want to change the form action. I want to redirect to another file (change form action if possible) if I click on second radio button How can I do that ? Thanks please reply soon. I have a HTML form that truncates the action parameter after the "?" mark - which is NOT the desired behavior I am looking for. I simply want to open the referenced URL within the same viewport. Here is a representative HTML snippet: HTML Code: <form action="http://www.spufalcons.com/index.aspx?tab=gymnastics&path=gym"> <input type="submit" value="Gymnastics"/> </form> In this case, the submit button takes you to the "http://www.spufalcons.com/index.aspx" page, effectively ignoring "?tab=gymnastics&path=gym" parameter. It appears that URL's using HTML and PHP pages referenced in the action=URL work as expected BUT (alas) this is not the case when the target page contains index.aspx. This behavior is consistent across all major browsers (IE, FF, Safari, Chrome, Opera). Has anyone seen this problem before? Or can suggest an alternative and/or workaround consistent with my "pure" CSS/HTML/PHP web development approach? I have tried replacing the special characters with HTML entity values with no impact. I REALLY don't want to use abandon my CSS-styled submit buttons by using Javascript or button PNG's or image maps. Environment: Web Server: Apache 2.2.14 PHP: 5.2.10 OS: Mac OS X 10.5.8 HTML document info: HTML Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> Hi all, I have a query that I hope somebody can help with as my site has been brought to a standstill because of this problem. I have just posted the new version of my site online and I have a folder below the domain root which contains things like database info, form scripts etc. When I process the form I get a 404 error. the action is something like HTML Code: action="../includes/process_form.php" There is no need to any output from these files as they process the information and direct to the relevant files above the domain root using php header scripts. At the beginning of most of my files I have the following PHP Code: <?php $security = 'secure'; require('../includes/default.php'); require('../includes/error_handlers.php'); require('../includes/db.php'); ?> and there is no problem with these whatsoever. I had all of the scripts working fine when I tested them at domainroot.co.uk/take2/public/ domainroot.co.uk/take2/includes/ Does anybody have any ideas why this is happening Any help would be appreciated John Hi, I'm a new member first post :] I have a website I'm working on and there is a problem with the existing forms. You fill them out and submit but get an error... Not Found The requested URL /cgi-t/form.cgi was not found on this server. This is probably due to incorrect directing of urls within the code do you think? [as] <font color="#255696" size="5" face="Arial"><b><br> </b></font> <FORM METHOD=POST ACTION="http://ledgerlaw.com/cgi-t/form.cgi"> [/as] maybe some problem here I see there is cgi?! Hi all, I have a simple form which is passing a value (e.g 324) to another page. e.g <option value='234' >Football for 8 to 10 year olds</option> I also need to pass the name, e.g Football.... Is it possible to pass two things at once in this way? many thanks, Martin. Hi there, I created a form, but have a hard time getting it to work properly when I test it with the cgiecho that I was told to use by my web host. Here's a link to the form page: http://www.harmonihomeconsulting.com/contact-hhc.htm I used a script that I found in this forum (renamed it to "submitForm") and adjusted it to reflect my inputs etc. with the goal of having certain fields be required when someone fills in the form. It seems to work when I fill in all the fields, but not when some are left blank. I selected the script as it seemed to be the easiest to understand for someone like myself that know basically nothing about scripts. My web host did provide instructions on another way to make the input required, but it doesn't seem to work either, so I went back to the script in hope of getting that to work, but with no luck. Any assistance with this would be greatly appreciated. Thanks for your help! Hello all, Having some problems with this form. <form id="form1" action="" enctype="multipart/form-data" name="form1"> <div style="padding-left:1px;"> <div class="fleft" style="width:208px;"> <span class="txt2">Enter Your Name:</span> <div class="form"><input type="text" value=" "/></div> <span class="txt2">Enter Your E-mail:</span> <div class="form"><input type="text" value=" "/></div> <span class="txt2">Enter Your State:</span> <div class="form"><input type="text" value=" "/></div> </div> <div class="fleft" style="width:250px;"> <span class="txt2">Enter Your Message:</span> <textarea name="textarea" cols="20" rows="10"></textarea><br /> <br style="line-height:15px;" /> <div class="fright"><a class="link2" href="#" onclick="document.getElementById('form1').reset()"><img alt="" src="images/clear.gif" /></a><img alt="" src="images/spacer.gif" width="17" height="1" /><a class="link2" href="#" onclick="document.getElementById('form1').submit()"><img alt="" src="images/send.gif" /></a></div> </div> I want to have it send the form information through an email account on our domain to a set of addresses. I read somewhere that I should change the information in the contact.asp document but I do not have one. I bought the template I am using and there was not one in the zip file. Do I need to create a contact.asp file? If so, how? Can I do something with the existing code? Any help is appreciated. Hi, I want to load a text file into HTML textarea, edit it and later save it. the following form fails to show the text a simple text file - 1.txt. ----- <html> <script> function saveFile (fname) { document.execCommand('SaveAs',null,fname) } function displayFile (text) { document.formName.file.value = text; } </script> <body> <form name="form1" method="post" action=""> <label>edit this file: <textarea name="textarea" rows="10" cols="50">displayfile("1.txt")</textarea> </label> <input type="button" value="Save" onClick="saveFile('1.txt');"> </form> </body> </html> ------ Ok. so here's the deal. I need to set my site up to where people can create login names w/ passwords etc. I have no clue where to start. Right now, I know how to create a username form and password form, but thats about it. any help?? Plz!?! |