pikemsu28 Posted September 19, 2006 Share Posted September 19, 2006 I need a point in the right direction!!!!! I have a form that has two sets of radio button groups being displayed dynamically. I want the second group to display information depending on the radio that was selected in the first group.EXAMPLE:Group 1 Group 2Clinical If Clinical Display: Team 1 Team 2Non Clinical If Non Clinical Display: Team 1 Team 2 Team 3General If General Display: Team 1 Team 2 Team 3 Team 4If someone could point me in the right direction on this it would greatly be appreciated.Thanks, JasonBTW I'm using Dreamweaver to code my PHP and using some PHP Built in functions of Dreamweaver. Link to comment https://forums.phpfreaks.com/topic/21279-a-point-in-the-right-direction/ Share on other sites More sharing options...
craygo Posted September 19, 2006 Share Posted September 19, 2006 Give us some of your code now so we can see what you have.Ray Link to comment https://forums.phpfreaks.com/topic/21279-a-point-in-the-right-direction/#findComment-94676 Share on other sites More sharing options...
pikemsu28 Posted September 19, 2006 Author Share Posted September 19, 2006 [code]<?phpmysql_select_db($database_Nursing, $Nursing);$query_teams = "SELECT team FROM teams";$teams = mysql_query($query_teams, $Nursing) or die(mysql_error());$row_teams = mysql_fetch_assoc($teams);$totalRows_teams = mysql_num_rows($teams);$x = 0;do { $team[$x] = $row_teams['team'];$x++;} while ($row_teams = mysql_fetch_assoc($teams));?><form method="post" name="teams" id="teams" onSubmit="return checkRadios(this);"><table width="250" align="center" border="1"><tr><td><?php for ($y = 0; $y < $totalRows_teams; $y++) { ?><label><input type="radio" name="team" value="<?php echo $team[$y]; ?>" /><?php echo $team[$y]; ?></br></label><?php } ?></td></tr><tr align="center"><td><input name="submit" type="submit" class="bluebox" id="submit" value="Submit" /><input name="reset" type="reset" class="bluebox" id="reset" value="Reset" /></td></tr></table></form>[/code]This code generates the first radio group through the sql query. How do i get this code to display the second radio group? I know how to do the form and the loop, just how to get this radio group to dynamically populate once the first radio group is selected. Link to comment https://forums.phpfreaks.com/topic/21279-a-point-in-the-right-direction/#findComment-94684 Share on other sites More sharing options...
craygo Posted September 19, 2006 Share Posted September 19, 2006 how are the groups defined in the table. Do you have a group id or something???Ray Link to comment https://forums.phpfreaks.com/topic/21279-a-point-in-the-right-direction/#findComment-94691 Share on other sites More sharing options...
pikemsu28 Posted September 19, 2006 Author Share Posted September 19, 2006 1st group:<input type="radio" name="team" id="team" value="<?php echo $team[$y]; ?>" />2nd group:name="team_assign"since i last posted my code i did add the id="team" into my code. Link to comment https://forums.phpfreaks.com/topic/21279-a-point-in-the-right-direction/#findComment-94741 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.