www.webdeveloper.com
Results 1 to 8 of 8

Thread: screen resolution

  1. #1
    Join Date
    Jun 2003
    Location
    Waycross, GA
    Posts
    6

    Question screen resolution

    I use the 1024 x 768 screen resolution and I have frames on my site... I have my site logo inside the frame, but when i changed the resolution to 800 x 600 to check out how the site looked, the image didn't fit on the frame. Is there a way to make the image fit well in both resolutions without having to make the image smaller or changing the frame percentage? (when it's smaller, you can't see the picture as well)
    Thank you very much.

    --mR. redniP
    Last edited by jackbobpin; 06-04-2003 at 07:24 PM.

  2. #2
    Join Date
    Dec 2002
    Location
    High on life
    Posts
    10,104
    You could do this:

    Code:
    <script language="javascript" type="text/javascript">
    if (screen.width <= 800) {
        document.myimage.src = "your800img.gif";
    }
    </script>
    </head>
    <body>
    <img src="your1024img.gif" name="myimage" />

    Personal website http://www.ryanbrill.com/
    Business website: http://www.infinitywebdesign.com/
    TypeSpace http://www.typespace.org/

    I reject your reality and substitute it with my own!

  3. #3
    Join Date
    Jun 2003
    Location
    Waycross, GA
    Posts
    6

    Unhappy mR. cluelesS speaks again

    hmmm... that didn't seem to work... i'm probably just changing the wrong thing I wouldn't be surprised
    Last edited by jackbobpin; 06-05-2003 at 01:42 PM.
    "...a triple threat."
    Shine.
    --mR. redniP

  4. #4
    Join Date
    Dec 2002
    Location
    High on life
    Posts
    10,104
    Oops... you need to put it in an onload event:

    Code:
    <script language="javascript" type="text/javascript">
    function swapImage() {
        if (screen.width <= 800) {
            document.myimage.src = "your800img.gif";
        }
    }
    </script>
    </head>
    <body onload="swapImage();">
    <img src="your1024img.gif" name="myimage" />

    Personal website http://www.ryanbrill.com/
    Business website: http://www.infinitywebdesign.com/
    TypeSpace http://www.typespace.org/

    I reject your reality and substitute it with my own!

  5. #5
    Join Date
    Jun 2003
    Location
    Waycross, GA
    Posts
    6
    well that still didn't work... let me make sure i'm changing the right thing: "your800image.gif" and "your1024image.gif" and that's all? sorry... i'm dumb
    "...a triple threat."
    Shine.
    --mR. redniP

  6. #6
    Join Date
    Dec 2002
    Location
    High on life
    Posts
    10,104
    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    </head>
    
    <script language="javascript" type="text/javascript">
    function swapImage() {
    	if (screen.width <= 800) {
    		document.myimage.src = "800.gif";
    	}
    }
    </script>
    </head>
    <body onload="swapImage();">
    <img src="1024.gif" name="myimage" />
    
    </body>
    </html>

    Personal website http://www.ryanbrill.com/
    Business website: http://www.infinitywebdesign.com/
    TypeSpace http://www.typespace.org/

    I reject your reality and substitute it with my own!

  7. #7
    Join Date
    Jan 2003
    Location
    Peg City
    Posts
    638
    I think pyro is saying that you should create a 1024x768 and an 800x600 image which you would then load depending on the screen resolution detected.

    Havik

  8. #8
    Join Date
    Jun 2003
    Posts
    16
    i wanna kwon, please hlep!
    Amazing Graphic Editor - Powerful and easy-to-use graphic editor and converter!
    Silver Eagle Software, Inc.
    http://www.SilverEagleSoft.com


Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles