Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script type="text/javascript" src="http://code.jquery.com/jquery.min.js"></script>
- <script language="javascript" type="text/javascript">
- $(function(){
- $('#check').click(function(){
- if (document.getElementById('check').checked == true) {
- $('#lol').removeAttr('disabled');
- } else if (document.getElementById('check').checked == false) {
- $('#lol').attr('disabled', 'disabled');
- }
- })
- })
- </script>
- <label>
- <input type="checkbox" id="check" /> My CheckBox
- </label>
- <br />
- <button id="lol" disabled="disabled">My Button</button>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement