|
|||
Switching background according to resolution
Hi all,
I am working on a project and the customer has requested that the background is able to change itself according to the monitor resolution set by the user. Eg:- if(resolution <= 1000) display.1024.jpg if(resolution <= 1100) display.1152.jpg and so on* [*Sorry for the broken Javascript :P] I've searched across the Internet and they only mostly teach you how to use Javascript to detect the resolution and pop-up a message to the user. Can someone assist in this Javascript question? Many thanks. |
|
||||
JavaScript is able to detect screen resolution but not da browser size I bliv.. then U can archive tis by switchin diff css file to change da background image accordin to client's screen resolution? Normally users r maximizin their web browser while surfin..
A List Apart: Articles: Alternative Style: Working With Alternate Style Sheets Switch CSS files with Javascript Mayb d easiest way.. change the background image while "body onLoad" document.body.background='.gif' Last edited by wingwp; 26-10-2007 at 04:34 PM. |
|
||||
A very nice script to detect wen User resizin his browser dynamically
original source from How to get browser width when resized [Archive] - WebDeveloper.com I mod a little & it work on my IE & FF Code:
<script>
window.onresize = myResize;
function myResize() {
if (document.all)
{document.getElementById('BrowsingSize').innerHTML = (document.body.clientWidth);}
else
{document.getElementById('BrowsingSize').innerHTML = (window.innerWidth);}
}
</script>
<div id="BrowsingSize"></div>
|
![]() |
«
Previous Thread
|
Next Thread
»
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to set layer for all screen resolution? | wyngzflower | Website Design | 1 | 08-02-2006 08:03 AM |
| screen resolution | honeyz | Website Design | 3 | 27-09-2005 09:26 AM |
| Switching host provider A.S.A.P. | MENJ | Paid Hosting Discussion Forum | 3 | 25-03-2004 10:24 PM |
| Switching host provider A.S.A.P. | MENJ | Mamak Stall | 0 | 23-03-2004 10:36 AM |
| what is the best resolution view for Web Designers.. | Ben-davis | Mamak Stall | 50 | 27-08-2003 01:18 PM |
All times are GMT +8. The time now is 05:13 AM.
Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0 vBulletin skin by ForumMonkeys.com.
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0 vBulletin skin by ForumMonkeys.com.









Linear Mode

