Skip to main content
September 10, 2008
Question

Checkbox and 2 functions

  • September 10, 2008
  • 3 replies
  • 250 views
I have a form that lists all games for a college football week. I am allowing users to select up to 7 teams. I am using checkboxes b/c it is easier to unselect a game. One thing that is important is if a user has select Team 1 for Game 1 and then for some reason select Team 2 of the same game I need to have a script that deselects Team 1. I have script that works for this. My problem becomes when I use a cfif statement and do not have consecutive GameID. For example, if a game has kicked off I do not want to show that game. Or if a user has selected a game already I do not want to show that game. This throws off my javascript and while I can still deselect an opponent if the opposite opponent is selected I can no longer use the count. Code is below, thanks.

    This topic has been closed for replies.

    3 replies

    Inspiring
    September 18, 2008
    have 3 buttons per game. team1, team2, and neither
    September 18, 2008
    I have but if I use radio then a user cannot uncheck as easily. If I use a reset then it would reset all.
    Inspiring
    September 10, 2008
    Have you considered radio buttons instead of check boxes? It would seem to be a lot simpler.