PHP Form Processing help?

  • Thread starter Thread starter ~!*^ÑÜMß^*!~
  • Start date Start date
Ñ

~!*^ÑÜMß^*!~

Guest
I have a form that I want to use with my website, but I don't know what I need to write in the separate file for the form's "action". I know it has to be PHP, if somebody out there can help, could you please give me a code? I've looked up this stuff on the PHP website and I still don't really understand it.

Basically, I want it to put all of the information into a text file and upload it to a directory to my site, the file would have to have a random name in case two files are the same, the text file would look like this:

Name: Example
Song: Example
Band: Example
Album: Example
Type: Tab or Lyrics

Body:

Body of whatever was submitted



This is the form I have..


<form action="form.php"> <!-- there is nothing in form.php right now, what do I put in it? //->

Name:
<input type="text" name="nameby" />
<br /><br />
Song:
<input type="text" name="song" />
<br /><br />
Band:
<input type="text" name="band" />
<br /><br />
Album:
<input type="text" name="album" />
<br /> <br />
Type:
<select name="type">
<option value="Lyrics">Lyrics</option>
<option value="Tab">Tab</option>
</select><br /> <br />
Body:<br /><br /><textarea rows="15" cols="60" name="body">Tab Or Lyrics Here</textarea>
<br /> <br />
<input type="submit" value="Submit" />

</form>



How can I make this work?
Thank you so much!

Once it's been 4 hours since the question has been up, you're getting best answer.
 
Back
Top