warydig Posted January 18, 2008 Share Posted January 18, 2008 when i create a form, all of the elements are treates as text boxes! below is my form: <FORM METHOD=\"POST\" ACTION=\"$SERVER[php_SELF]\"> <P><strong>Your Name:</strong><br> <INPUT type=\"text\" NAME =\"sender_name\" </P> <P><strong>Your E-Mail Address:</strong><br> <INPUT type=\"text\" NAME =\"sender_email\" SIZE=30></P> <P><strong>Your Message:</strong><br> <TEXTAREA NAME=\"message\" COLS=30 ROWS=5 WRAP=virtual></TEXTAREA></P> <INPUT type=\"hidden\" name=\"op\" value=\"ds\"> <P><INPUT type=\"submit\" NAME=\"submit\" VALUE=\"Send Your Message\"></P> </FORM>"; the hidden field and the submit button come out as text boxes like the other text boxes! why is this?? Link to comment https://forums.phpfreaks.com/topic/86646-solved-newbie-question/ Share on other sites More sharing options...
papaface Posted January 18, 2008 Share Posted January 18, 2008 Try: echo '<form method="POST" action="'.$_SERVER['PHP_SELF'].'"> <p><strong>Your name:</strong> <input type="text" name ="sender_name" </p> <p><strong>Your E-Mail Address:</strong> <input type="text" name ="sender_email" size="30"></p> <p><strong>Your Message:</strong> <textarea name="message" cols="30" rows="5" wrap="virtual"></textarea></p> <input type="hidden" name="op" value="ds"> <p><input type="submit" name="submit" value="Send Your Message"></p> </form>'; Link to comment https://forums.phpfreaks.com/topic/86646-solved-newbie-question/#findComment-442784 Share on other sites More sharing options...
warydig Posted January 18, 2008 Author Share Posted January 18, 2008 This worked! Told you i was a newbie thanks very much! Link to comment https://forums.phpfreaks.com/topic/86646-solved-newbie-question/#findComment-442788 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.