Results 1 to 5 of 5

Thread: Flash Control HTML BG Image

  1. #1
    Join Date
    Apr 2006
    Posts
    584
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Flash Control HTML BG Image

    Can Flash control the bg image on a HTML page? I basically have 6 menu items within Flash and when the user clicks on a new button, I want the bg to change, the bg is inside a the HTML page... I realise I could just add the bg image to the Flash file, but want to keep the combo of HTML and Flash... Any ideas?

  2. #2
    Join Date
    Apr 2007
    Location
    Phoenix, AZ
    Posts
    64
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I have had success with the externalInterface class. It's not in the regular documentation, but it is online. You can use it to call javascript functions directly from the Flash movie.

  3. #3
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    Do each of the buttons in your flash link to a new HTML page? If so, why not just change the background through HTML or CSS?

  4. #4
    Join Date
    Apr 2007
    Location
    New York
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I don't know much about Flash, but Javascript can do this easily.

  5. #5
    Join Date
    Jan 2007
    Location
    Charlotte, NC
    Posts
    82
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default

    You could pass variables from flash to html and vice versa using this:

    Code:
    swfsource?mybg=1
    in every instance the source is used in the html embed and object tags. mybg would be the variable with a value of 1.

    You could then write a javascript function that displays a specified bg depending on the variable passed from flash.

    Hope this helps

Bookmarks

Posting Permissions

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