Quote Originally Posted by Design75 View Post
Hi philip,

I know you reported this a while back, but since i am updatig this module, I thought to give you an update on this.

The more/less button works fine when using jquery 1.4.4, but with higher versions it stops. Now we need to find out why :)

The other updates to be included for now are all the code bugfixes / improvements reported in this thread since version 1.1 was released.
Resolved

If using jquery 1.6.0 or newer, change the contents of file includes\templates\YOUR_TEMPLATE\jscript\dynamic_filter\jquery.dynamic_filter.mi n.js
Code:
$("div.dynamicfilterContent").eq(0).ready(function(){$('ul.dFilterExpand').each(function(){if($(this).attr("scrollHeight")>130)$(this).height(130).siblings('a.dFilterToggle').show();});$("a.dFilterToggle").click(function(){if($(this).siblings("ul.dFilterExpand").height()==130){$('.dFilterToggleImg',$(this)).attr('src',$('.dFilterToggleImg').attr('src').replace('_more','_less')).attr('alt','Less').attr('title','Less');$(this).html($(this).html().replace("More","Less"));$(this).siblings("ul.dFilterExpand").animate({height:$(this).siblings("ul.dFilterExpand").attr("scrollHeight")},"slow");}else{$('.dFilterToggleImg',$(this)).attr('src',$('.dFilterToggleImg').attr('src').replace('_less','_more')).attr('alt','More').attr('title','More');$(this).html($(this).html().replace("Less","More"));$(this).siblings("ul.dFilterExpand").animate({height:130},"slow");}
return false;});});
to
Code:
$("div.dynamicfilterContent").eq(0).ready(function(){$('ul.dFilterExpand').each(function(){if($(this).prop("scrollHeight")>130)$(this).height(130).siblings('a.dFilterToggle').show();});$("a.dFilterToggle").click(function(){if($(this).siblings("ul.dFilterExpand").height()==130){$('.dFilterToggleImg',$(this)).attr('src',$('.dFilterToggleImg').attr('src').replace('_more','_less')).attr('alt','Less').attr('title','Less');$(this).html($(this).html().replace("More","Less"));$(this).siblings("ul.dFilterExpand").animate({height:$(this).siblings("ul.dFilterExpand").prop("scrollHeight")},"slow");}else{$('.dFilterToggleImg',$(this)).attr('src',$('.dFilterToggleImg').attr('src').replace('_less','_more')).attr('alt','More').attr('title','More');$(this).html($(this).html().replace("Less","More"));$(this).siblings("ul.dFilterExpand").animate({height:130},"slow");}
return false;});});
.attr("scrollHeight") becomes .prop("scrollHeight") (2x)