【问题标题】:Full browser flash works in Safari 5 but not Firefox 3.6完整的浏览器闪存在 Safari 5 中有效,但在 Firefox 3.6 中无效
【发布时间】:2010-12-07 05:27:39
【问题描述】:

谁能告诉我为什么这个标记在 Safari 中可以正常工作,但在 Firefox 中却不行?

这应该加载一个丑陋的蓝色占位符(我在 safari 中得到),但在 Firefox 中,swfobject 只是给了我替代内容。

http://www.johndierks.com/stackoverflow/preloader.html

感谢您的帮助。

这是我从 SwfObject 的 google 代码站点获得的代码供参考。

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
    <head>
        <title>SWFObject 2 full browser flash</title>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
        <style type="text/css" media="screen">
            html, body, #content    { height:100%; }
            body                    { margin:0; padding:0; overflow:hidden; }
            #altContent             { /* style alt content */ }
        </style>        
        <script type="text/javascript" src="swfobject.js"></script>
        <script type="text/javascript">
        swfobject.registerObject("myId", "9.0.0", "expressInstall.swf");
        </script>

    </head>
    <body>
        <div id="content">  
            <object id="myId" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100%" height="100%">
                <param name="movie" value="ccholidaypreloader.swf" />
                <!--[if !IE]>-->
                <object type="application/x-shockwave-flash" data="test6.swf" width="100%" height="100%">
                <!--<![endif]-->
                <div id="altContent">

                    <h1>Alternative content</h1>
                    <p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>
                </div>
                <!--[if !IE]>-->
                </object>
                <!--<![endif]-->
            </object>
        </div>

    </body>
</html>

【问题讨论】:

    标签: javascript flash debugging cross-browser swfobject


    【解决方案1】:

    404 未找到 http://www.johndierks.com/stackoverflow/test6.swf (来自萤火虫)

    【讨论】:

    • @约翰。没问题。使用 firebug,打开“显示网络错误”,它对于开发/调试非常方便。它会立即向您显示任何因 404 失败的内容,对于拼写错误等非常方便
    猜你喜欢
    • 1970-01-01
    • 2018-11-30
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-03-20
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多