I have a check box and 3 textboxes, what i want is to disable all 3 textboxes when check box is checked. For that i have done this code but not working.
<tr>
<td><?php echo "Modify Default Package Dimensions:"; ?></td>
<td><input type="checkbox" name="Modify_Default_Dimensions" value="1" onclick="document.getElementsByClassName('hide_textbox').disabled=this.checked;"></td>
</tr>
<td><?php echo "Depth"; ?></td>
<td><input type="text" class="hide_textbox" name="dhl_product_depth" value="<?php echo $product_depth ?>" /> cm</td>
</tr>
<tr>
<td><?php echo "Width"; ?></td>
<td><input type="text" class="hide_textbox" name="dhl_product_width" value="<?php echo $product_width ?>" /> cm</td></tr>
<tr>
<td><?php echo "Height"; ?></td>
<td><input type="text" class="hide_textbox" name="dhl_product_height" value="<?php echo $product_height ?>" /> cm</td>
</tr>