Menu
I’m trying to set my wrapper div width so it fits to screen res. i got it working but it only works when i call it by onclick=”SetWidthToResolution()” function and i want it to load with the page.
function SetWidthToResolution()
{
if(screen.width == 2560)
{
document.getElementById(“wrapper”).style.width=”1280px”;
}
}
If i place
if(screen.width == 2560)
{
document.getElementById(“wrapper”).style.width=”1280px”;
}
in <head> it doesnt do anything
Please help, its driving me crazy