1 Replies - 699 Views - Last Post: 10 January 2009 - 02:24 PM Rate Topic: -----

#1 chris_s_22  Icon User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 74
  • Joined: 27-December 08

how do i add this form data to my database

Posted 10 January 2009 - 01:12 PM

this is a form that once filled to make enteries into my database, firstly what tables feild names do i need, secondly what do i add to my functions.php page thirdly what will be entered in my creategame.php

 
<form action="creategame.php" method="post">   
<input type='text' name='players0' size='35' value='Player 1'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players1' size='35' value='Player 2'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players2' size='35' value='Player 3'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players3' size='35' value='Player 4'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players4' size='35' value='Player 5'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players5' size='35' value='Player 6'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players6' size='35' value='Player 7'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players7' size='35' value='Player 8'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players8' size='35' value='Player 9'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players9' size='35' value='Player 10'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players10' size='35' value='Player 11'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players11' size='35' value='Player 12'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players12' size='35' value='Player 13'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players13' size='35' value='Player 14'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
<input type='text' name='players14' size='35' value='Player 15'>
<select><option value='M'>Male</option><option value='F'>Female</option></select><br>
Select a  tareget score<select name="finalscore">
     <option>20</option>
     <option>25</option>
     <option>30</option>
     <option>35</option>
     <option>40</option>
     <option>45</option>
     <option>50</option>
     <option>55</option>
     <option>60</option>
     <option>65</option>
     <option>70</option>
     <option>75</option>
     <option>80</option>
     <option>85</option>
     <option>90</option>
     <option>55</option>
     <option>100</option>
     </select>
<input type="submit" name="submit" value="PLAY GAME" />
</form>
 


Is This A Good Question/Topic? 0
  • +

Replies To: how do i add this form data to my database

#2 CTphpnwb  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3001
  • View blog
  • Posts: 10,393
  • Joined: 08-August 08

Re: how do i add this form data to my database

Posted 10 January 2009 - 02:24 PM

That's just a bunch of html. You need to provide the php code that is generating it. The php code should have some sort of loop that generates the repetitive information.

The php files, tables and fields are up to you. It's your database and your code.

This post has been edited by CTphpnwb: 10 January 2009 - 02:24 PM

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1