Morph A Fixed Background Image To Another Background Image'

Discussion in 'JavaScript' started by buckmajor, Oct 20, 2008.

  1. #1
    Hi there

    I've been searching for answers and still haven't found it yet, does anyone know 'HOW TO CHANGE FROM ONE FIXED BACKGROUND IMAGE TRANSITION TO ANOTHER FIXED BACKGROUND IMAGE' without using flash? So on top of the background, I want to have content e.g text, graphics etc

    Or alternative can anyone tell me how you can change the background image fading when someone click on a new page. I hope that makes sense.

    Many thanks in advance.
    CHEERS :)
     
    buckmajor, Oct 20, 2008 IP
  2. lp1051

    lp1051 Well-Known Member

    Messages:
    163
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    108
    #2
    Hi, if you use :
    your_element.style.backgroundImage = 'new_image/path/img.gif';
    you change the image only, so all other properties defined for background remains. Hope you're looking for this...
    your_element is the reference to the background container - use document.getElementById('your_element_id') if it has ID...
    For fading effects you can use some ready made scripts, or libs, just search on net. Then select that you want to fade - your_element.style.backgroundImage, and all text on top will be still visible
     
    lp1051, Oct 20, 2008 IP
  3. Bind

    Bind Peon

    Messages:
    70
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #3
    are you talking about on a page change or will you have a selector so it does it all on one web page ?
     
    Bind, Oct 20, 2008 IP