Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Browser information using Javascript (mainly display size) 1

Status
Not open for further replies.

nishttal

Programmer
Nov 5, 2001
2
0
0
US
Hi All,
I am writing an application where I need to figure out certain characteristics of the requesting browser...
- display size (width X height)
- device type (handheld or PC)

is it possible to do so ?.. i know a site ( that does this.. it shows the content only if all requirements are met and shows the error message (with all your browser information) otherwise.

can somebody please point me to the solution for this.

thanks,
Nishant
 
well this is server side(e.g:ASP), u have to use the request.servervariable which gives a whole lot of info about the system (including screen size etc)....

Known is handfull, Unknown is worldfull
 

Using Javascript, you can use "screen.width" and "screen.height" to determine the resolution of the user's system.

Hope this helps,
Dan
 
>>device type (handheld or PC)

those details can be had only from server variables...

Known is handfull, Unknown is worldfull
 
what server variable are you talking about ?
 
asp server variables...

Known is handfull, Unknown is worldfull
 
I have to determine if the device is a handheld or PC and then serve out the appropriate web page.

Did you ever put some code together?

Paul Orlowski
orlowpr@bp.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top