TOpham Posted February 11, 2008 Share Posted February 11, 2008 Hello wondering if this is possible, Im after a drop down list that shows Ranks from cadet all the way upto General (UK Ranks), so it inputs the rank what ever the drop down is but then puts a number that corresponds to that rank in a different colum in same table.Thanks in advance,Mathew Link to comment Share on other sites More sharing options...
real_illusions Posted February 11, 2008 Share Posted February 11, 2008 A database table you mean?If so, you can pass the drop down box as a variable using method="post" in a form, and write it to a database where you have one table row as rank and stores it as that rank rather than a number.Is that what your after or something completely different? Link to comment Share on other sites More sharing options...
teng84 Posted February 11, 2008 Share Posted February 11, 2008 $qry =mysql_query('slect * from tble order by rank');echo '<select name="">'; while($row = mysql_fetch_array($qry)){echo '<option value="'.$row['rankid'].'">'.$row['ranki'].'</option>';}echo '</select>'; Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.