internet explorer - jQuery UI Check Button doesn't stay Highlighted IE 8 -


i using jquery ui button element checkbox. idea works toggle button. button pressed , stays in 'pressed'/'active' state until clicked again, checkbox button visual interface user.

my problem button not stay in pressed state in internet explorer. works correctly in other browsers. when if click button, , press anywhere else on page, button appear unpressed/default/inactive.

javascript:

$('#btnoptions').button({     icons: {         primary: "ui-icon-wrench"     } })   $('#btnoptions').click(function (event) {     event.preventdefault();     loadoptions(); });  

html:

<input type="checkbox" id="btnoptions" /><label for="btnoptions">options</label> 

any ideas? thanks

well turns out idiot!

this line of code doing it:

 event.preventdefault(); 

i had in there convention because when buttons links, use prevent page jumping top. time preventing default behaviour!

so code works follows:

$('#btnoptions').click(function (event) {     loadoptions(); });  

Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -