Jump to content
xisto Community
wannabeeaweak

making a form

Recommended Posts

here is a form that u can input into your html codeing<FORM ACTION="file:///{documents}//http//http://forums.xisto.com/no_longer_exists/; METHOD="POST"> <P ALIGN=CENTER>First name:*:<INPUT TYPE="TEXT" NAME="fisrt name" SIZE=20 onBlur="if ( !exists ( this value)) { alert ( Please enter first name') ; } "> Gender: <SELECT NAME=" the_Gender" STYLE="width: 0.77in; height: 0.23in"> <OPTION SELECTED>Female <OPTION>Male</OPTION> </SELECT> </P> <P ALIGN=CENTER>Last name:*:<INPUT TYPE=TEXT NAME="TextField2" SIZE=20 STYLE="width: 1.71in; height: 0.25in"></P> <P ALIGN=CENTER>Type of game:* <SELECT NAME="type of games" STYLE="width: 1.25in; height: 0.23in"> <OPTION SELECTED>game type <OPTION>Shooting <OPTION>Action <OPTION>Kids games <OPTION>Adventure <OPTION>RPG <OPTION>Figthing <OPTION>classic <OPTION>sports <OPTION>every thing elese</OPTION> </SELECT> </P> <P ALIGN=CENTER>Webpage URL:<INPUT TYPE=TEXT NAME="TextField3" SIZE=20 STYLE="width: 1.71in; height: 0.25in"></P> <P><BR><BR> </P> <P><TEXTAREA ROWS=16 COLS=49 STYLE="width: 4.29in; height: 2.99in">Put games link and picture html </TEXTAREA></P> <P ALIGN=CENTER><INPUT TYPE=SUBMIT NAME="CommandButton1" VALUE="SUBMIT" STYLE="width: 0.61in; height: 0.24in"> <INPUT TYPE=RESET NAME="CommandButton2" VALUE="RESET" STYLE="width: 0.54in; height: 0.24in"> </P> </FORM>

Share this post


Link to post
Share on other sites

mmm this form .... ok ... you press submit, but the data, where it goes ???? email, dbase, page ???
this form is incomplete, well if you started i have one a little better to send mail from a webpage.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html> <head> <title>Send your comments</title> </head> <body bgcolor="#cccc66" text="#003300" link="#006060" vlink="#006060"> <? if (!$HTTP_POST_VARS){ ?> <form action="form.php" method=post> Name: <input type=text name="name" size=16> <br> Email: <input type=text name=email size=16> <br> Comments: <textarea name=comment cols=32 rows=6></textarea> <br> <input type=submit value="Send"> </form> <? }else{     $body = "sent form\n";     $body .= "Nane: " . $HTTP_POST_VARS["name"] . "\n";     $body .= "Email: " . $HTTP_POST_VARS["email"] . "\n";     $body .= "Comments: " . $HTTP_POST_VARS["comment"] . "\n";     //send mail...     mail("name@host.com","Received Form",$body);     //thanks for email    echo "Thanks for fill the form. It has been sent correctly."; } ?> </body> </html>

now you have to save this code with the name "form.php" and put in your server.

If you want some more advanced and better features go to http://forums.xisto.com/no_longer_exists/

they have a lot of scripts, mail forms, gallery, tell a friend, etc. and all free. The scripts have a little link to stadtaus.com, if you want to use without the link, you have to buy this script.

Share this post


Link to post
Share on other sites

wannabeeaweak, the code you provided is a nightmare.

 

Anybody who read this and considdered using this code, DON'T

 

First of all, making a form is as easy as slicing pie.

<form> and </form>

All done.

 

Then adding elements to that form is just as easy. Something where you want to type text in one line?

<input type="text" />

All done.

 

What did you say? A list where you can select things? Sure, why not?

<select>
<option> You can select this </option>
<option> Or select this </option>
<option selected="selected"> But this will be selected by default </option>
</select>

And I know, you want a button to submit all the results as well,

<input type="submit" />

Or if you rather have a custom text on the button:

<input type="submit" value="Click here to submit the stuff ;)" />

 

All those of your choice inbetween the <form> and </form> tags, and you're all done. Here's an example including all of them (I included <br /> to go to a new line as well):

<form action="the_results_go_to_this_file.html">

Your name:<br />
<input type="text" /><br />

Your gender:<br />
<select>
 <option> Male </option>
 <option> Female </option>
</select><br />

<input type="submit" />

</form>

 

Now, wannabeeaweak, as for what you said:

First of all, your code is flawed. Badly. You open loads of tags which you never close. The option tag, for example. Secondly, you include evil javascript, with alerts etc. Horrible. Thirdly, not only is your code riddled with errors, it's also messy and unreadable, it doesn't follow any standards, you use upercase tags where they should be lowercase, you don't use quotes around attributes, you don't close your tags, and whatevermore.

Don't try and help people that don't know how to make forms by means of this .. ..... incorrect code.

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.