[Flex] IFrame系列 —— IFrame嵌入html点击其他组件后页面消失的问题
2016-06-02 11:00
716 查看
在flex建的web项目中,打开index.template.html,将param.wmode = "transparent";添加到以下位置
以下位置可不添加,建议添加。
问题解决。
<script type="text/javascript" src="swfobject.js"></script> <script type="text/javascript"> // For version detection, set to min. required Flash Player version, or 0 (or 0.0.0), for no version detection. var swfVersionStr = "${version_major}.${version_minor}.${version_revision}"; // To use express install, set to playerProductInstall.swf, otherwise the empty string. var xiSwfUrlStr = "${expressInstallSwf}"; var flashvars = {}; var params = {}; params.quality = "high"; params.bgcolor = "${bgcolor}"; params.allowscriptaccess = "sameDomain"; params.allowfullscreen = "true"; params.wmode = "transparent"; var attributes = {}; attributes.id = "${application}"; attributes.name = "${application}"; attributes.align = "middle"; swfobject.embedSWF( "${swf}.swf", "flashContent", "${width}", "${height}", swfVersionStr, xiSwfUrlStr, flashvars, params, attributes); // JavaScript enabled so display the flashContent div in case it is not replaced with a swf object. swfobject.createCSS("#flashContent", "display:block;text-align:left;"); </script>
以下位置可不添加,建议添加。
<noscript> <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="${width}" height="${height}" id="${application}"> <param name="movie" value="${swf}.swf" /> <param name="quality" value="high" /> <param name="bgcolor" value="${bgcolor}" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="allowFullScreen" value="true" /> <param name="wmode" value="transparent" /> <!--[if !IE]>--> <object type="application/x-shockwave-flash" data="${swf}.swf" width="${width}" height="${height}"> <param name="quality" value="high" /> <param name="bgcolor" value="${bgcolor}" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="allowFullScreen" value="true" /> <param name="wmode" value="transparent" /> <!--<![endif]--> <!--[if gte IE 6]>--> <p> Either scripts and active content are not permitted to run or Adobe Flash Player version ${version_major}.${version_minor}.${version_revision} or greater is not installed. </p> <!--<![endif]--> <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> <!--[if !IE]>--> </object> <!--<![endif]--> </object> </noscript>
问题解决。
相关文章推荐
- 学习HTML:iframe用法总结收藏
- XML与html的区别
- HTML DOM cursor 属性
- html溢出部分加滚动条
- HTML学习笔记(2)
- HTML DOM Event 对象
- 好一道简单的html试题
- Html(10) - get和post方法的区别
- html元素大小与位置讲解
- HTML tag
- html中加入超链接方式的汇总
- 发送html内容的email(转)
- html注册界面
- HTML table和form的讲解
- Razor和HtmlHelper的使用意义
- (selenium 四)unittest生成HTMLTestRunner报告
- HtmlUnit解析动态网页并采集网页列表到Excel
- 通过offset值的设置使html元素对齐
- html绘制五角星。。
- HTML学习笔记(3) - HTML标签