Ell20 Posted November 3, 2007 Share Posted November 3, 2007 Hey guys, Im working on a sports club website. I have in place already fixtures and teams for a particular club. Now id like to be able to select players to play in each fixture. I have created a teamselection.php page which I have created a dynamic drop down box to list all the fixtures that are linked to the club which the user is logged into. From here, once the user has selected the fixture, I want to create a list of the players currently selected as playing in that game. For this I have created a new table called team_selection which will be used to store the players that are playing in each fixture. Here is my code so far: <table width="60%" align="center" cellpadding="0" cellspacing="0" border="0" class="game"> <tr> <th colspan="2"> Team Selection </th> </tr> <tr> <td width="63%"> <b> Select Fixture You Wish To View Team Selection For: </b> </td> <td align="center"> <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post"> <select name="fixturedrp"><option value='' selected disabled>Select Fixture</option> <?php $sql = "SELECT * FROM fixtures WHERE club_id = '$id'"; $result = mysql_query($sql); while($row = mysql_fetch_array($result)){ $fixture_id = $row["fixture_id"]; $team = $row["team"]; $opponents = $row["opponents"]; $fixture = "$team Vs $opponents"; ?> <option value="<?php echo $fixture_id ?>"><?php echo $fixture ?></option> <?php } ?> </select> </td> </tr> <tr> <td width="63%"> </td> <td align="center"> <input name="submit" type="submit" value="Select Fixture" /> </form </td> </tr> </table> How would I go about the adding players to the fixture? Cheers Link to comment https://forums.phpfreaks.com/topic/75921-php-help/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.