Check Box Enable Disable Script

In this Check Box Enable Disable Script is used to enable or disable a check box on this browser.

Demo :



  Check box 1 Check box 2 Check box 3    

Example :

You just click in Disable button then ask confirm message is like "Are You Sure?, You Want to Disable This Check box". If you click which confirm ok check box will be disable. This will happen again and again based on your enable and disable clicking buttons.

Code :

Following code is use to disable and enable for a check box.If you need to copy and use it.


<?php
function disable_enable_fun()
{
  if(document.getElementById('button').value =='Disable')
  {
    document.frm_check_box.check_box[0].disabled=true;
    document.frm_check_box.check_box[1].disabled=true;
    document.frm_check_box.check_box[2].disabled=true;
    document.getElementById('button').value ='Enable';
  }
  else
  {
    document.frm_check_box.check_box[0].disabled=false;
    document.frm_check_box.check_box[1].disabled=false;
    document.frm_check_box.check_box[2].disabled=false;
    document.getElementById('button').value ='Disable';
  }
}
?>

In the above disable_enable_fun() function have using to disable and enable for a Check box.When you click in the Disable button will execute disable_enable_fun() function and in the check box will disabled and button value will change to Enable.

Free Download Script:

If you need to Check Box Enable Disable Script click and download from following zip file.

Download




Content