HTML Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsWeb DesignHTML Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 27th, 2011, 04:19 PM
Orfantal Orfantal is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2011
Posts: 7 Orfantal User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 49 m 38 sec
Reputation Power: 0
Form submit button not working

hi can someone help with this problem.

my submit button will not do anything

my code for the form is:

Code:

<div id="contact_form"
	<form name="contact" action="send_mail.php" method="post">
		Name: <input style="width:180px;"type="text" name="name"></input><br><br>
		Telephone: <input style="width:180px;"type="text" name="telephone"></input><br><br>
		E-mail: <input style="width:180px;"type="text" name="email_address"></input><br><br>
		<label style="vertical-align: top;">Message:</label>
		<textarea style="width:179px" type="text" name="message" rows="8"></textarea><br><br>
		<input id="submit" type="submit" value="Send Message"></input>
	</form>
</div>


i tested the form code in a seperate page to the one i want it in and it does work, could it be my css or sumthing like that stopping it?

Thanks in advance

Reply With Quote
  #2  
Old February 27th, 2011, 08:52 PM
bford21 bford21 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2010
Posts: 17 bford21 User rank is Corporal (100 - 500 Reputation Level)bford21 User rank is Corporal (100 - 500 Reputation Level)bford21 User rank is Corporal (100 - 500 Reputation Level)bford21 User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 6 h 56 m 26 sec
Reputation Power: 0
There were a few issues. One tags like <input> are self closing. Meaning they don't need a closing tag like </input>. You just close it with a "/". Same thing with your <br /> tags you needed the "/".

Heres what your code should look like. I haven't tested it but it should work.

Code:
<div id="contact_form">
 <form name="contact" action="send_mail.php" method="post">
  Name: <input style="width:180px;"type="text" name="name" />
  <br />
  <br /> 
  Telephone: <input style="width:180px;"type="text" name="telephone" />
  <br />
  <br /> 
  E-mail: <input style="width:180px;"type="text" name="email_address" />
  <br />
  <br /> 
  <label style="vertical-align: top;">Message:</label>
  <textarea style="width:179px" type="text" name="message" rows="8"></textarea>
  <br />
  <br /> 
  <input id="submit" type="submit" value="Send Message" />
 </form> 
</div>

Reply With Quote
  #3  
Old February 28th, 2011, 08:08 AM
Orfantal Orfantal is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2011
Posts: 7 Orfantal User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 49 m 38 sec
Reputation Power: 0
Thanks that did work, cant believe it was something so simple

Reply With Quote
  #4  
Old March 3rd, 2011, 05:53 AM
wulaishiwo wulaishiwo is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2011
Posts: 2 wulaishiwo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 18 m 5 sec
Reputation Power: 0
<input id="submit" type="submit" value="Send Message"></input>

should write like this

<input id="submit" type="submit" value="Send Message" />

Reply With Quote
  #5  
Old August 25th, 2012, 01:49 AM
rakesg rakesg is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2012
Posts: 1 rakesg User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 m 39 sec
Reputation Power: 0
Quote:
Originally Posted by Orfantal
hi can someone help with this problem.

my submit button will not do anything

my code for the form is:

Code:

<div id="contact_form"
	<form name="contact" action="send_mail.php" method="post">
		Name: <input style="width:180px;"type="text" name="name"></input><br><br>
		Telephone: <input style="width:180px;"type="text" name="telephone"></input><br><br>
		E-mail: <input style="width:180px;"type="text" name="email_address"></input><br><br>
		<label style="vertical-align: top;">Message:</label>
		<textarea style="width:179px" type="text" name="message" rows="8"></textarea><br><br>
		<input id="submit" type="submit" value="Send Message"></input>
	</form>
</div>


i tested the form code in a seperate page to the one i want it in and it does work, could it be my css or sumthing like that stopping it?

Thanks in advance



Hi, I see you are missing the closing ">" in the <div> tag.
<div id="contact_form" .... use <div id="contact_form">

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignHTML Programming > Form submit button not working

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap