54uydf 1 Junior Poster

I have a form with 2 submit buttons,
inside the form I have a table, each row in a table has a checkbox
each row is showing a member-status, each member can have more than 1 status, so the table looks like this-
x=checkbox

x, david, beginner
x, david, pro
x, david, other
x, marc, begginer
x, tony, pro
..
..

I want to get a popout window in case that more than 1 checkbox was checked for the same member (for david in this case), notify the user to uncheck one of them. how do I do this?

the code for david's first row is:

<td width="3%"><center><input [B]data-column="1"[/B] type="checkbox" name="checkbox[]" id="checkbox[]"  value="david"/></center></td>

the code for david's second row is:

<td width="3%"><center><input [B]data-column="2" [/B]type="checkbox" name="checkbox[]" id="checkbox[]"  value="david"/></center></td>

the code for david's third row is:

<td width="3%"><center><input [B]data-column="2" [/B]type="checkbox" name="checkbox[]" id="checkbox[]"  value="david"/></center></td>

the 2 (deny all selected/approve all selected) buttons:

<button type="submit" class="positive" name="submit1"> approve all</button>
 <button type="submit" class="negative" name="submit2"> deny all</button>';

and the form

<form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>">

please help, I don't know javascript :confused:

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.