Created
June 22, 2012 15:46
-
-
Save Itachicz11/2973599 to your computer and use it in GitHub Desktop.
Here is myjs.js file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if($('#iph_check').next().attr('checked')){ | |
$('#iph_check').iphoneSwitch("on", | |
function() { | |
if($('#iph_check').next().attr('checked')){ | |
//then checked attribute exist so modify it! | |
$('#iph_check').next().prop('checked', !$checkbox[0].checked); | |
}else{ | |
$('#iph_check').next().attr('checked', true); | |
} | |
}, | |
function() { | |
$('#iph_check').next().attr('checked', false); | |
}, | |
{ | |
switch_on_container_path: 'iphone_switch_container_off.png' | |
}); | |
}else{ | |
$('#iph_check').iphoneSwitch("off", | |
function() { | |
if($('#iph_check').next().attr('checked')){ | |
//then checked attribute exist so modify it! | |
$('#iph_check').next().prop('checked', !$checkbox[0].checked); | |
}else{ | |
$('#iph_check').next().attr('checked', true); | |
} | |
}, | |
function() { | |
$('#iph_check').next().attr('checked', false); | |
}, | |
{ | |
switch_on_container_path: 'iphone_switch_container_off.png' | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment