resize background image for master page

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • orked
    New Member
    • Jan 2009
    • 49

    resize background image for master page

    i want to use image as background for master page, i want this image to resize it's size according to screen size or the browser i put image as background for master using this code
    Code:
    <body background="images/abstract-background.jpg">
    Thanks
    orked
  • Frinavale
    Recognized Expert Expert
    • Oct 2006
    • 9749

    #2
    I don't think it's possible to do this with CSS alone.
    I could be wrong but I would think that you would have to have an image element and re-size it using JavaScript. Your content would have to go on top of the image...which means that every thing would have to have a style of position:absolu te.


    -Frinny
    Last edited by Frinavale; Aug 31 '10, 01:27 PM. Reason: Removed moderation message.

    Comment

    • JKing
      Recognized Expert Top Contributor
      • Jun 2007
      • 1206

      #3
      You could use javascript to determine screen resolution and browser onload and then set the background-image from there.

      Comment

      Working...