|
|||||||
Join now to download all the free website templates or post on the forum. If you have never been on a forum before read the
FAQ. It's quick, easy and free to join!
|
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
Hello,
Can anyone help with a suggestion or tips about how can i find the user resolution when enter on my website, and if that resolution is higher or lower (eg: or = 1024) then the image from header to change in another one? Thanks |
|
||||
|
Code:
<script type="text/javascript">
if ((screen.width<=1024) && (screen.height<=768)) {
window.location.replace('http://example.com/1024-768-or-less');
}
else {
window.location.replace('http://example.com/greater-than-1024-768');
}
</script>
__________________
cleandeck - lawn mower undercoating and wilmargraphite - graphite lubricants |
![]() |
| Thread Tools | |
| Display Modes | |
|
|