I have the code that works at current
jQuery.event.add(window, "load", resizeFrame);
jQuery.event.add(window, "resize", resizeFrame);
function resizeFrame()
{
var w = $(window).width();
$('.resize').css('width', (w <= 1680) ? 1680 : 1920);
}
but now i need to add in other screen sizes, such as:
$('.resize').css('width', (w <= 1280) ? 1280 : 1920);
$('.resize').css('width', (w <= 1024) ? 1024 : 1920);
but im unsure about how to chain these together, ive tried using || but this didn’t work
help appreciated
1 Answer