Can somebody explain to me,how to add If inside If I mean something like that:
$(window).resize(function(){
if ($(window).width()<1000)
{
$('.search-trigger').on('click',function(){
if($('.search-overlay').hasClass('show'))
$('.search-overlay').removeClass('show');
}
else
{
$('.search-overlay').addClass('show');
}
});
}
});
If browser window is under 1000px ,turn on other search-menu style (full overlay search page), when click on search button. I'm using this code at the moment and got a error in console,which is:
Uncaught SyntaxError: missing )
after argument list. Please if somebody can explain to me how to add If into If,to fix my search menu.THANKS !!