[Flex] IFrame系列 —— 嵌入本地页面两种方式source和content(html页面和html代码)
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600" xmlns:ns="http://code.google.com/p/flex-iframe/">
<s:layout>
<s:VerticalLayout/>
</s:layout> <fx:Script>
<![CDATA[
protected function iframe1_frameLoadHandler(event:Event):void
{ }
]]>
</fx:Script> <fx:Declarations>
<!-- 将非可视元素(例如服务、值对象)放在此处 -->
<!-- HTML content stored in a String -->
<fx:String id="iframeHtmlContent">
<![CDATA[
<html>
<head>
<title>About</title>
</head>
<body>
<div>About</div>
<p>Simple HTML Test application. This test app loads a page of html locally.</p>
<div>Credits</div>
<p> </p>
<p>IFrame.as is based on the work of</p>
<ul>
<li><a href="http://www.cnblogs.com/frost-yen/p/5527395.html" target="_top">Frost.Yen cnblogs -- 在flex的web应用中嵌入html的方法</a></li>
<li><a href="http://www.cnblogs.com/frost-yen/" target="_top">Frost.Yen cnblogs</a></li>
</ul>
</body>
</html>
]]>
</fx:String>
</fx:Declarations>
<s:Panel title="flex嵌入html代码" width="80%" height="80%">
<ns:IFrame id="iframe1" width="100%" height="100%" overlayDetection="true" content="{iframeHtmlContent}" frameLoad="iframe1_frameLoadHandler(event)">
</ns:IFrame>
</s:Panel>
<s:Panel title="flex嵌入本地html页面" width="80%" height="80%">
<ns:IFrame id="iframe2" width="100%" height="100%" overlayDetection="true" source="about.html">
</ns:IFrame>
</s:Panel>
</s:Application>
about.html
<html>
<head>
<title>About</title>
</head>
<body>
<div>About</div>
<p>Simple HTML Test application. This test app loads a page of html locally.</p>
<div>Credits</div>
<p> </p>
<p>IFrame.as is based on the work of</p>
<ul>
<li><a href="http://www.cnblogs.com/frost-yen/p/5527395.html" target="_top">Frost.Yen cnblogs -- 在flex的web应用中嵌入html的方法</a></li>
<li><a href="http://www.cnblogs.com/frost-yen/" target="_top">Frost.Yen cnblogs</a></li>
</ul>
</body>
</html>
[Flex] IFrame系列 —— 嵌入本地页面两种方式source和content(html页面和html代码)的更多相关文章
- SpringCloud系列-整合Hystrix的两种方式
Hystrix [hɪst'rɪks],中文含义是豪猪,因其背上长满棘刺,从而拥有了自我保护的能力.本文所说的Hystrix是Netflix开源的一款容错框架,同样具有自我保护能力. 本文目录 一.H ...
- fetch更新本地仓库两种方式:
来源:https://www.cnblogs.com/chenlogin/p/6592228.html //方法一 $ git fetch origin master //从远程的origin仓库的m ...
- Python下载图片并保存本地的两种方式
一:使用Python中的urllib类中的urlretrieve()函数,直接从网上下载资源到本地,具体代码: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 ...
- java中调用本地动态链接库(*.DLL)的两种方式详解和not found library、打包成jar,war包dll无法加载等等问题解决办法
我们经常会遇到需要java调用c++的案例,这里就java调用DLL本地动态链接库两种方式,和加载过程中遇到的问题进行详细介绍 1.通过System.loadLibrary("dll名称,不 ...
- WCF服务使用(IIS+Http)和(Winform宿主+Tcp)两种方式进行发布
1.写在前面 刚接触WCF不久,有很多地方知其然不知其所以然.当我在[创建服务->发布服务->使用服务]这一过程出现过许多问题.如客户端找不到服务引用:客户端只在本机环境中才能访问服务,移 ...
- java 多线程之卖票两种方式
1.通过extends Thread /* 需求:简单的卖票,多个窗口同时买票 (共用资源) 创建线程的第二种方式:实现Runnable接口 步骤: 1,定义类实现Runnable接口 2,覆盖/重写 ...
- WebView加载页面的两种方式——网络页面和本地页面
WebView加载页面的两种方式 一.加载网络页面 加载网络页面,是最简单的一种方式,只需要传入http的URL就可以,实现WebView加载网络页面 代码如下图: 二.加载本地页面 1.加载asse ...
- Flex(ActionScript)与JavaScript交互的两种方式示例
随着各单位部门信息化进程的不断发展,互通互联.共享协调不断的被越来越多的客户所重视.很多新项目都要去必须能够集成已有的早期系统,至少也要能够实现交互对接.今天跟大家分享的是系统对接中ActionScr ...
- linux内核分析作业4:使用库函数API和C代码中嵌入汇编代码两种方式使用同一个系统调用
系统调用:库函数封装了系统调用,通过库函数和系统调用打交道 用户态:低级别执行状态,代码的掌控范围会受到限制. 内核态:高执行级别,代码可移植性特权指令,访问任意物理地址 为什么划分级别:如果全部特权 ...
随机推荐
- python2.7处理https稍微好点的办法(坑得一笔)
from warnings import filterwarnings filterwarnings('ignore') r = requests.get(url, headers=headers, ...
- python_day7【模块configparser、XML、requests、shutil、系统命令-面向对象】之篇
python内置模块补充 一.configparser configparser:用户处理特定格式的文件,其本质是利用open打开文件 # 节点 [section1] #键值对k1 = v1 k2:v ...
- android 实现拍照的2种方法
android系统的照相功能,已实现2种方法,可供大家参考: 1.调用系统摄像头来拍照 首先,找到AndroidManifest.xml文件里加入用户权限 <uses-permission an ...
- Nginx出现413 Request Entity Too Large错误解决方法
Nginx出现的413 Request Entity Too Large错误,这个错误一般在上传文件的时候出现,打开nginx主配置文件nginx.conf,找到http{}段,添加 解决方法就是 打 ...
- 如何通过源码生成Gatling可执行工具
其实,这个对于不是很熟系sbt的人来说,或者对scala语言没有什么了解的人,接触Gatling这个开源的性能测试框架,还是有些茫然的. 因为GitHub上提供的Gatling (最新版本:2.2.0 ...
- [转]Linux环境下查看线程数的几种方法
1.cat /proc/${pid}/status 2.pstree -p ${pid} 3.top -p ${pid} 再按H,或者直接输入 top -bH -d 3 -p ${pid} top ...
- 不包含适合于入口点的静态"Main"方法
学习新建项目.此问题做为笔记. 错误 1 程序“admin.exe”不包含适合于入口点的静态“Main”方法 原因:原来创建项目的时候,用的是“空项目”,我以为这样就会生成类库,实际上,一开始准备运行 ...
- 基于.net开发chrome核心浏览器
本文转载自:http://www.cnblogs.com/liulun/archive/2013/04/20/3031502.html 一: 上一篇的链接: 基于.net开发chrome核心浏览器[一 ...
- golang的的模板引擎之pongo2
https://github.com/flosch/pongo2 beego的扩展包 https://github.com/yansuan/beego-pongo2 gin的扩展包 https://g ...
- C#:基于WMI查询USB设备
来源:http://blog.csdn.net/jhqin/article/details/6734673 /* ------------------------------------------- ...