注册 登录  
 加关注
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

神魔破杜梓的叨叨堂

Programming every day!

 
 
 

日志

 
 
 
 

Flash 中嵌入Html页面  

2008-06-05 20:38:37|  分类: My Tech |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |
原文来自deitte.com
Flash 中嵌入Html页面 - hydra1983 - Edisons Closet

I've updated to Flex 2 the code by Christophe Coenraets for embedding HTML in a Flex application using an iframe.

You can see a demo of it here.

You can download the code here.

To run locally, first compile IFrameDemo.mxml. If you are using Flex Builder, unclick "Generate HTML wrapper file" in the Flex Compiler settings before publishing, since there is an existing HTML wrapper. After this, you can view IFrameDemo.html. If you get a "Security sandbox violation" error, you need to put the IFrameDemo directory in the local-trusted sandbox. See the Flex documentation for information on updating FlashPlayerTrust files.

The one cause for limitations in this code is the use of opaque for wmode. I've seen reports of tabbing problems in the player, and running more than one player when using opaque wmode seems to degrade performance.

I had previously updated Christophe's code twice for Flex betas. The two posts (which are here and here) have been very popular, and I'm happy to finally be able to update this code to Flex final.

This update also includes minor improvements to the code for readability and polish.

Update: if you'd like to share your own experiences with HTML in Flex or read what others have to say, see my new post on this.

Update 2: see this post for an update to the code that allows multiple HTML pages to be referenced at once.

Update 3: see this post for an update to the code that needs less HTML changes, allows multiple HTML pages to be referenced at once, and controls the HTML visibility as needed.


  评论这张
 
阅读(687)| 评论(0)
推荐 转载

历史上的今天

评论

<#--最新日志,群博日志--> <#--推荐日志--> <#--引用记录--> <#--博主推荐--> <#--随机阅读--> <#--首页推荐--> <#--历史上的今天--> <#--被推荐日志--> <#--上一篇,下一篇--> <#-- 热度 --> <#-- 网易新闻广告 --> <#--右边模块结构--> <#--评论模块结构--> <#--引用模块结构--> <#--博主发起的投票-->
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2017