HTML above Flash in firefox using SwfObject?

Posted on 2010-01-03
Last Modified: 2012-05-08

I'm trying to get some html to appear above flash in a web page. It works fine in IE however I can't get it to appear above the flash in firefox. How do I achieve this?

I've been told I can just add this text and it should work:

params.wmode = transparent;

But where would I add it?

Any help much appreciated.
Question by:iDeej
    LVL 11

    Expert Comment

    You have to put it in the script part where you load the swf object.

    Please have a look at this:
    LVL 11

    Accepted Solution

    Do it something like this:

    <script type="text/javascript">
    var params = {};
    params.wmode = "transparent";
    swfobject.embedSWF("myFlash.swf", "myFlash", "300", "200", "8.0.0","expressInstall.swf", params);

    Open in new window

    LVL 4

    Author Comment

    I've looked into using swf object a little more and if possible to achieve what I'm trying to do I would like to use the static publishing method as described on this page:

    I'm told I can make the flash swf transparent by entering this code twice:

    <param name="wmode" value="transparent" />  

    I have done this and it is still not working.

    Is there something I need to do in CSS besides setting the z-index to make this work?

    Should I be using the dynamic publishing method?
    LVL 4

    Author Comment

    Thanks for your efforts kusala,

    I am still leaning towards using static publishing with the Swf Object but in case I can't get that to work I tried your code above and now it is not working in any browsers.

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    <html xmlns="" lang="en" xml:lang="en">
            <title>My Title</title>
            <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
            <link rel="stylesheet" type="text/css" href="styles/master.css" />
            <script type="text/javascript" src="scripts/swfobject.js"></script>
            <script type="text/javascript">
                var params = {};
                params.wmode = "transparent";
                swfobject.embedSWF("myMovie.swf", "flashDiv", "955", "495", "9.0.0","expressInstall.swf", params);

            <div id="container">
                <div id="flashDivContainer">
                    <div id="flashDiv">

    Any ideas?
    LVL 4

    Author Closing Comment

    I ended up doing something like this and so far it is working well in all browsers except safari on windows. I have not tested on safari on mac.

    Just a not on the code too, I think you will need to add in a few more parameters otherwise it won't work, flashvars even if there are none.

    Thanks for your help.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
    Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
    The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
    The goal of the tutorial is to teach the user what frame rate is, how to control it and what effect it has on the video.

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now