#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2000
    Posts
    20
    Rep Power
    0
    Is there a way to determine the client's screen resolution using a php function, javascript, or other way?

    Thanks
  2. #2
  3. .Net Developer
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    London
    Posts
    987
    Rep Power
    15

    I don't think any php function is available for this.Since this is the client side issue .you will have use Java Script for finding out resolution.


    ------------------
    SR -
    shiju.dreamcenter.net

    "The fear of the LORD is the beginning of knowledge..."
  4. #3
  5. Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    Perth West Australia
    Posts
    757
    Rep Power
    15
    This is an oldie but you can dig out the screen res' bit from it.

    function fourplus() {
    browser = (((navigator.appName == "Netscape") &&
    (parseInt(navigator.appVersion) >= 4 )) | |
    ((navigator.appName == "Microsoft Internet Explorer") &&
    (parseInt(navigator.appVersion) >= 4 )))
    lessthanseven=(window.screen.width <=700)
    morethanseven=(window.screen.width >=700)
    bigbugger=(window.screen.width >= 900)

    if (browser && bigbugger) {
    openpopup()
    }
    else

    if (browser && lessthanseven) {
    window.location = "640/location.html";
    }
    else
    if (browser && morethanseven) {
    window.location = "http://www.designerjewel.com.au/splittemp.html";
    }
    else
    window.location="nobrowser.html";
    }

    I have not found a detect screen res solution in PHP but I am sure???? someone has one ? - well hoping anyway.


    ------------------
    Simon Wheeler
    FirePages -DHTML/PHP/MySQL

Similar Threads

  1. How to resize frame according to screen resolution???
    By skuba in forum HTML Programming
    Replies: 10
    Last Post: January 5th, 2004, 05:51 PM
  2. Form load. Bottom of screen. Whatever the resolution?
    By Newman_SCO in forum Visual Basic Programming
    Replies: 2
    Last Post: September 30th, 2003, 06:35 AM
  3. Right justify new window regardless of screen resolution
    By UncleMole in forum HTML Programming
    Replies: 4
    Last Post: August 19th, 2003, 06:08 PM
  4. Resizing an iframe based on screen resolution?
    By Luxotr in forum HTML Programming
    Replies: 1
    Last Post: July 31st, 2003, 02:19 PM
  5. Changing image size because of screen resolution
    By nindoja in forum HTML Programming
    Replies: 1
    Last Post: June 7th, 2003, 07:20 PM

IMN logo majestic logo threadwatch logo seochat tools logo