Age old question: How to make an image stretch to 100% of window

Discussion in 'HTML' started by Lee Harris, Jan 8, 2004.

  1. Lee Harris

    Lee Harris Guest

    Here is my web page
    http://www.bombersgolf.com/BLT/home.html

    I want to change the top pane which currently has a gif on top of a
    background colour and replace it with a single image which I have optimised
    to 1024*200. It won't tile well, so I would like to know how (ideally
    fitting in with the html I have there now) I can put my image in place so
    that it will fit exactly once across the top of the page, stretching or
    contracting if the screen size is not 1024

    thanks in advance
    Lee
    Lee Harris, Jan 8, 2004
    #1
    1. Advertising

  2. Lee Harris

    Steve R. Guest

    Lee Harris wrote in message ...
    > I want to change the top pane which currently has a gif on top of a
    > background colour and replace it with a single image .....


    It seems to work ok as it, merging into the background colour.

    The only thing I'd add that it's too tall taking up 200 pixels in height on
    every page. You are forgetting the viewers who are using 800x600 who are
    losing a large proportion of their viewing area because of the height of
    the image, which will require a lot more *unnecessary* vertical scrolling.

    Also the forum opens in a 'new window' instead pof being part of the
    website.
    Steve R., Jan 8, 2004
    #2
    1. Advertising

  3. Lee Harris wrote:

    > I can put my image in place so
    > that it will fit exactly once across the top of the page, stretching or
    > contracting if the screen size is not 1024


    <img src="foobar" alt="Foo Bar" style="height: 128px; width: 99%;">

    --
    Toby A Inkster BSc (Hons) ARCS
    Contact Me - http://www.goddamn.co.uk/tobyink/?page=132
    Toby A Inkster, Jan 8, 2004
    #3
  4. Lee Harris

    Steve R. Guest

    Steve R. wrote in message ...
    > Also the forum opens in a 'new window' instead of being part of the
    > website.


    Trying to be helpful now, you could make the forum as part of the website
    by using a header frame like this, then the menus links to the frameset.
    http://freespace.virgin.net/temp.files/frames/top_bottom.htm

    It's even more important now to make your image/s at the top a lot less
    tall :~}
    Steve R., Jan 8, 2004
    #4
  5. Lee Harris

    Lee Harris Guest

    "Steve R." <stevie_ritchie(NOSPAM)@hotmail.com> wrote in message
    news:4FjLb.10084$...
    > Lee Harris wrote in message ...
    > > I want to change the top pane which currently has a gif on top of a
    > > background colour and replace it with a single image .....

    >
    > It seems to work ok as it, merging into the background colour.
    >
    > The only thing I'd add that it's too tall taking up 200 pixels in height

    on
    > every page. You are forgetting the viewers who are using 800x600 who are
    > losing a large proportion of their viewing area because of the height of
    > the image, which will require a lot more *unnecessary* vertical scrolling.
    >
    > Also the forum opens in a 'new window' instead pof being part of the
    > website.
    >
    >


    No, the image I want to use is 1024*200 as mentioned in the original post.
    It can't be bled into a background colour as it is a "proper picture".
    Thanks for the advice about 200 tall, I may have to narrow it up,but still
    need to know how to make it stretch once across the window, whatever the
    size, akin to <img src="x.jpg" width="100%"></img> kind of idea

    The forum window intentionally opens in a new window, although I know some
    consider that to be bad form
    Lee Harris, Jan 8, 2004
    #5
  6. Lee Harris

    Lee Harris Guest

    "Steve R." <stevie_ritchie(NOSPAM)@hotmail.com> wrote in message
    news:pYjLb.10099$...
    > Steve R. wrote in message ...
    > > Also the forum opens in a 'new window' instead of being part of the
    > > website.

    >
    > Trying to be helpful now, you could make the forum as part of the website
    > by using a header frame like this, then the menus links to the frameset.
    > http://freespace.virgin.net/temp.files/frames/top_bottom.htm
    >
    > It's even more important now to make your image/s at the top a lot less
    > tall :~}
    >
    >
    >


    I thought frames were the spawn of satan!
    anyway, hope you spotted my other reply about the image- the one shown is
    not the one I am intending to use, so your initial reply won't work
    thanks mate
    Lee Harris, Jan 8, 2004
    #6
  7. In article <YejLb.370$>, Lee
    Harris says...
    > Here is my web page
    > http://www.bombersgolf.com/BLT/home.html
    >
    > I want to change the top pane which currently has a gif on top of a
    > background colour and replace it with a single image which I have optimised
    > to 1024*200. It won't tile well, so I would like to know how (ideally
    > fitting in with the html I have there now) I can put my image in place so
    > that it will fit exactly once across the top of the page, stretching or
    > contracting if the screen size is not 1024


    Re-sizing images with a browser is a bad idea, but:

    http://www.dualstone.co.uk/stuff/bombers/home.html

    Check the page source and the bottom of your style sheet:

    http://www.dualstone.co.uk/stuff/bombers/style100.css

    Personally, I think the original looks fine. Why not just keep the logo
    on the left?

    --
    Daniel Ruscoe
    http://www.dualstone.co.uk
    Web design in Bolton, Manchester
    Daniel Ruscoe, Jan 8, 2004
    #7
  8. Lee Harris

    Steve R. Guest

    Lee Harris wrote in message ...
    > I thought frames were the spawn of satan!


    Nothing wrong with using frames if they are done *properly*.

    The problem is that the HTML nesgroups are dominated by 'purists' but in
    the real world frames are alive and working ok in most instances :~)
    Steve R., Jan 8, 2004
    #8
  9. Lee Harris

    Mark Parnell Guest

    On Thu, 08 Jan 2004 22:17:15 GMT, Steve R.NOSPAM declared in alt.html:

    > Lee Harris wrote in message ...
    >> I thought frames were the spawn of satan!


    Not quite, but they are definitely A Bad Thing(TM).

    >
    > Nothing wrong with using frames if they are done *properly*.


    There is a lot wrong with frames, partly because they are rarely, if
    ever done properly. And the alternatives are generally a lot less work
    than doing the frames properly in the first place.

    >
    > The problem is that the HTML nesgroups are dominated by 'purists' but in


    http://ppewww.ph.gla.ac.uk/~flavell/www/html-smac.html

    > the real world frames are alive and working ok in most instances :~)


    Depends on your definition of "working". :)

    --
    Mark Parnell
    http://www.clarkecomputers.com.au
    Mark Parnell, Jan 8, 2004
    #9
  10. Lee Harris

    Lee Harris Guest

    "Toby A Inkster" <> wrote in message
    news:p...
    > Lee Harris wrote:
    >
    > > I can put my image in place so
    > > that it will fit exactly once across the top of the page, stretching or
    > > contracting if the screen size is not 1024

    >
    > <img src="foobar" alt="Foo Bar" style="height: 128px; width: 99%;">
    >


    thanks, that was exactly what I was looking for.
    Lee Harris, Jan 9, 2004
    #10
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?iso-8859-1?B?bW9vcJk=?=
    Replies:
    7
    Views:
    805
    Roedy Green
    Jan 2, 2006
  2. cylin
    Replies:
    6
    Views:
    564
    Mike Wahler
    Aug 19, 2003
  3. TAM
    Replies:
    1
    Views:
    368
    David Dorward
    Apr 30, 2004
  4. fred
    Replies:
    3
    Views:
    257
    Zifud
    Mar 17, 2005
  5. Replies:
    5
    Views:
    862
Loading...

Share This Page