Looking for a method to create a matrix of radio buttons.
Easy enough, but here's the trick:
buttons must be mutually exclusive in both rows and columns.
Let's say they're in a 5x5 table (hence, the matrix)
If the user selects the button at row 2, column 1
all other buttons in row 2 and column 1 must be unchecked
I can do either a row or a column, but have not been able to do both.
Most of my work will be with PHP and HTML.
Last edited by Enki; 07-06-2006 at 09:25 PM.
Reason: Changing the title/subject line
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." Brian W. Kernighan
for matrixes, its often simpler to use multidimensional arrays. Like say the first radio is num, the second will be num all the way to the last one num. so you only need to create two loops, one to uncheck all with the same x-element, and one to uncheck all with the same y-element
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)