<a id="element1" onClick="javascript:changeText(0);docheck(this);">Mark</a> <input type="radio" id="element11" onClick="javascript:changeText11(1);docheck11(this);" name="test11" checked="checked"><br /> <script> function changeText11(idElement) { var element = document.getElementById('element' + idElement); if (idElement === 1 || idElement === 2) { if (element.innerHTML === 'Mark') element.innerHTML = 'Unmark'; else { element.innerHTML = 'Mark'; } } } var check; $('input[type="radio"]').hover(function() { check = $(this).is(':checked'); }); $('input[type="radio"]').click(function() { check = !check; $(this).attr("checked", check); }); var checkedradio; function docheck11(thisradio) { if (checkedradio == thisradio) { thisradio.checked = false; checkedradio = null; } else {checkedradio = thisradio;} } </script>
var checkedradio;
if (checkedradio == thisradio)
docheck11
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)