I am using prestashop 1.6.x.x along with the blocklayred navigation module to filter results on my category list page. I want to hide the category description when filtering the results...
I added this code which hides the category description, but it does not show the category description back when unchecked...
$(document).ready(function () {
$('.checkbox').on('change', function () {
$("#categorydesc").toggle(500);
});
});
Below is the code of the module:
var ajaxQueries = new Array();
var ajaxLoaderOn = 0;
var sliderList = new Array();
var slidersInit = false;
// Rest of the code goes here...
/**
* Copy of the utf8_decode() function in PHP.
*/
function utf8_decode (utfstr) {
var res = '';
for (var i = 0; i < utfstr.length;) {
var c = utfstr.charCodeAt(i);
if (c < 128)
{
res += String.fromCharCode(c);
i++;
}
else if((c > 191) && (c < 224))
{
var c1 = utfstr.charCodeAt(i+1);
res += String.fromCharCode(((c & 31) << 6) | (c1 & 63));
i += 2;
}
else
{
var c1 = utfstr.charCodeAt(i+1);
var c2 = utfstr.charCodeAt(i+2);
res += String.fromCharCode(((c & 15) << 12) | ((c1 & 63) << 6) | (c2 & 63));
i += 3;
}
}
return res;
}