How to prevent Flash player from reloading using iframe?

I have a website with a huge background. I need to put the flash player at the top of the website and I just figured out that every page they click on is a new page and thus restarting the Flash player. So I would like to put this flash player in an iframe so that it will keep playing all over the users surfing.

But my problem is, will the iframe cover the background image and not under it? Or does the background image of the page (not the iframe) fit well with the iframe and no one gets the wiser of my methods? Any help would be greatly appreciated.

+2


source to share


2 answers


First, you want to place the content of the individual pages in an iframe (not a flash video), since that's what you want to update. You want the flash to be on the actual parent page so that it always stays the same. (or put both in separate iframes and only update the iframe content).

As for your question about iframes, you can make it transparent so that the background can still be seen through it.

To do this, set the ALLOWTRANSPARENCY property to true on your iframe for example.



<iframe width="100%" height="500px" name="content" src="home.html" frameborder=0 allowtransparency="true"></iframe>

      

And then on the pages that the iframe will contain, set the body background to be transparent:

<body style="background-color:transparent">

      

+2


source


Ifragms are bad and take all the shitty stuff about frames with them (google "why frames are bad" if you want to read).

What you should be looking at are some AJAX techniques. JavaScript frameworks like Dojo and jQuery have many features you could check out. This will allow users to do things like vote, add to favorites, or comment while a movie is playing - pretty much like Youtube.



It all depends on what you are using under your HTML pages. Could you provide more information on this?

-1


source







All Articles