Привет, ребята, следующий фрагмент кода jQuery, кажется, прекрасно работает в Google Chrome и Opera, но ничего не происходит, когда я пытаюсь скрыть / показать соответствующий div в Internet Explorer или Firefox. Есть идеи?
$(function() {
$(".paste-meta-small .right a.collapse").click(function(event) {
$(this).parents(".paste-meta-small").next(".highlight").toggle(500);
$(this).text($(this).text() == 'show' ? 'hide' : 'show');
event.preventDefault();
})
})
$(function() {
$(".highlight-meta a.blog-collapse").click(function(event) {
$(this).parents(".highlight-meta").next(".blog-highlight").toggle(500);
$(this).text($(this).text() == 'show' ? 'hide' : 'show');
var margin = ($(this).text() == "show" ? "15px" : "0");
$(this).parents(".highlight-meta").css("margin-bottom", margin);
event.preventDefault();
})
})
Рабочий пример можно найти здесь
Заранее спасибо