Robert Solly Posted May 31, 2015 Share Posted May 31, 2015 I am trying to improve one or two of my websites by using a Send email script and adding a larger text box to the form.I can't get the textarea function to work properly. It creates the textarea box but it puts the code for the "reset" and "submit" buttons inside the box??? How can I get the "reset" and "Submit" buttons below the textarea box?Here is the original code without textarea:<!DOCTYPE html><html><body><h2>Send e-mail to someone@example.com:</h2><form action="MAILTO:someone@example.com" method="post" enctype="text/plain">Name:<br><input type="text" name="name" value="your name"><br>E-mail:<br><input type="text" name="mail" value="your email"><br>Comment:<br><input type="submit" value="Send"><input type="reset" value="Reset"></form></body></html>Result:Send e-mail to someone@example.com:Name:E-mail:Comment: (This is a one line comment area.)The send and reset buttons are here-----------------------------------------------------------------------------------I then changed the code below to include a textarea:<!DOCTYPE html><html><body><h2>Send e-mail to someone@example.com:</h2><form action="MAILTO:someone@example.com" method="post" enctype="text/plain">Name:<br><input type="text" name="name" value="your name"><br>E-mail:<br><input type="text" name="mail" value="your email"><br>Comment:<br><textarea name="comments"rows=10 cols=65 wrap>Comments?/textarea><input type="submit" value="Send"><input type="reset" value="Reset"></form></body></html>------------------------------------------------------------------------As I stated above, the input types (actually the last 5 lines from above) are then in the textarea box.What am I missing here?Thanks for any and all help.Chuck Link to comment Share on other sites More sharing options...
dsonesuk Posted May 31, 2015 Share Posted May 31, 2015 (edited) '<' on closing '/textarea> should be</textarea>It thinks '/textarea> and beyond is part of textarea element content, eventually the browser will close the textarea itself before its parent element form closing tag '</form>‘ Edited May 31, 2015 by dsonesuk Link to comment Share on other sites More sharing options...
Robert Solly Posted May 31, 2015 Author Share Posted May 31, 2015 dsonesuk, I am still a newbie at this. Thanks for finding the dumb mistake. I should learn to code in the morning instead of late at night. Chuck Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now