homepage Welcome to WebmasterWorld Guest from 54.237.249.10
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Subscribe to WebmasterWorld

Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
Forum Library, Charter, Moderator: open

JavaScript and AJAX Forum

    
Availible Width/Height
I bet this one has been done before.
jsbwm




msg:1482356
 6:33 pm on Dec 22, 2001 (gmt 0)

Hey everyone sorry to ask this but i couldn't find anything on it. I was wondering how to get the available width and height of a user's screen in NS6. I tried using innerHeight and innerWidth but couldn't get any results.
Thanks alot,
-jim

 

keyplyr




msg:1482357
 6:47 pm on Dec 22, 2001 (gmt 0)

one way is with JavaScript:

<!--
self.moveTo(0,0);self.resizeTo(screen.availWidth,screen.availHeight);
//-->

add the opening and closing tags

added: sorry, not sure for NS6

tedster




msg:1482358
 7:15 pm on Dec 22, 2001 (gmt 0)

Yes, it's screen.availWidth and screen.availHeight

The screen.width and screen.height properties show you the full resolution of the display.

screen.availWidth, and screen.availHeight shows you the size of the display that is not consumed by permanent fixtures of the browser and operating system, such as the Microsoft Internet Explorer menus and Windows Task Bar.

All four properties (and others) are available on both IE and Netscape browsers. The screen object is documented at Microsoft Link [msdn.microsoft.com] and Netscape Link [developer.netscape.com].

PC Mag Reference [pcmag.com]

jsbwm




msg:1482359
 8:18 pm on Dec 22, 2001 (gmt 0)

Thanks alot. Exactly what i was looking for!
-jim

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved