javascript - slideToggle() does not work properly in IE7 -


i experiencing problems jquery slidetoggle in ie7. works in ie8, ie9, ff, chrome, opera. when debug don't errors. thing that's happening event.preventdefault() reason ie7 isn't trying after if statement. here code:

/* handling of open/close toggler button categories */ $('ul.categories').on('click', '.toggle button', function(event) {     event.preventdefault();     var $categories = $(this).parent().next('.items'),         $icon = $('.icon', this);     $categories.slidetoggle(interface.animationduration, function() {         //somewhere here stops. not slidetoggle.         if ($(this).is(':visible')) {             $icon.removeclass('white-arrow-down').addclass('white-arrow-up');         } else {             $icon.removeclass('white-arrow-up').addclass('white-arrow-down');         }     }); });  <ul class="categories">     <li class="toggle"><button type="button"><span class="icon white-arrow-down"></span></button></li>     <ul class="items">         <li>             <input type="radio" name="category" id="" value=""><label for=""></label>         </li>         <li>         <input type="radio" name="category" id="" value=""><label for=""></label>         </li>     </ul> </ul> 

the issue due nested ul. not wrapped inside li made declaration faulty since using .parent():

var $categories = $(this).parent().next('.items') 

Comments

Popular posts from this blog

java - activate/deactivate sonar maven plugin by profile? -

python - TypeError: can only concatenate tuple (not "float") to tuple -

java - What is the difference between String. and String.this. ? -