Flex4 flashVars 传值
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <!-- saved from url=(0014)about:internet -->
- <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
- <!--
- Smart developers always View Source.
- This application was built using Adobe Flex, an open source framework
- for building rich Internet applications that get delivered via the
- Flash Player or to desktops via Adobe AIR.
- Learn more about Flex at http://flex.org
- // -->
- <head>
- <title>${title}</title>
- <meta name="google" value="notranslate" />
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <!-- Include CSS to eliminate any default margins/padding and set the height of the html element and
- the body element to 100%, because Firefox, or any Gecko based browser, interprets percentage as
- the percentage of the height of its parent container, which has to be set explicitly. Fix for
- Firefox 3.6 focus border issues. Initially, don't display flashContent div so it won't show
- if JavaScript disabled.
- -->
- <style type="text/css" media="screen">
- html, body { height:100%; }
- body { margin:0; padding:0; overflow:auto; text-align:center;
- background-color: ${bgcolor}; }
- object:focus { outline:none; }
- #flashContent { display:none; }
- </style>
- <!-- Enable Browser History by replacing useBrowserHistory tokens with two hyphens -->
- <!-- BEGIN Browser History required section ${useBrowserHistory}>
- <link rel="stylesheet" type="text/css" href="history/history.css" />
- <script type="text/javascript" src="history/history.js"></script>
- <!${useBrowserHistory} END Browser History required section -->
- <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 = {employeeName:"中文",language:"en_US"};
- var params = {};
- params.quality = "high";
- params.bgcolor = "${bgcolor}";
- params.allowscriptaccess = "sameDomain";
- params.allowfullscreen = "true";
- var attributes = {};
- attributes.id = "${application}";
- attributes.name = "${application}";
- attributes.align = "middle";
- swfobject.embedSWF(
- "${swf}.swf?version=1.0", "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>
- </head>
- <body>
- <!-- SWFObject's dynamic embed method replaces this alternative HTML content with Flash content when enough
- JavaScript and Flash plug-in support is available. The div is initially hidden so that it doesn't show
- when JavaScript is disabled.
- -->
- <div id="flashContent">
- <p>
- To view this page ensure that Adobe Flash Player version
- ${version_major}.${version_minor}.${version_revision} or greater is installed.
- </p>
- <script type="text/javascript">
- var pageHost = ((document.location.protocol == "https:") ? "https://" : "http://");
- document.write("<a href='http://www.adobe.com/go/getflashplayer'><img src='"
- + pageHost + "www.adobe.com/images/shared/download_buttons/get_flash_player.gif' alt='Get Adobe Flash player' /></a>" );
- </script>
- </div>
- <noscript>
- <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="${width}" height="${height}" id="${application}">
- <param name="movie" value="${swf}.swf?version=1.0" />
- <param name="quality" value="high" />
- <param name="bgcolor" value="${bgcolor}" />
- <param name="allowScriptAccess" value="sameDomain" />
- <param name="allowFullScreen" value="true" />
- <param name="FlashVars" value="employeeName=中文&language=en_US"/>
- <!--[if !IE]>-->
- <object type="application/x-shockwave-flash" data="${swf}.swf?version=1.0" 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="FlashVars" value="employeeName=中文&language=en_US"/>
- <!--<![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>
- </body>
- </html>
flashvars 传值
传递的方式一致:
<param name="FlashVars" value="myName=julabs&myHometown=china" />
或
<embed src="demo.swf" FlashVars="myName=julabs&myHometown=china" ........ />
或
demo.swf??u1=good&u2=bad
其中可以在FlashVars中指定,也可以通过
movie或 src中的swf url指定参数,修改所有包含flashvar的地方
获取flashVars的值
Flex4中获取flashVars值:(Flex4的取值方式与Flex3不同)
xxx = FlexGlobals.topLevelApplication.parameters.employeeName;
xxx = FlexGlobals.topLevelApplication.parameters.language;
Flex3中的取值方式为:
XXX = Application.application.parameters.employeeName;
Flex4 flashVars 传值的更多相关文章
- mono for android Listview 里面按钮 view Button click 注册方法 并且传值给其他Activity 主要是context
需求:为Listview的Item里面的按钮Button添加一个事件,单击按钮时通过事件传值并跳转到新的页面. 环境:mono 效果: 布局代码 主布局 <?xml version=" ...
- ASP.NET MVC 5 Web编程5 -- 页面传值的方式
本篇文章将讲述MVC的页面传值方式,具体包括:后端向前端传值(Controller向View传值):前端向后端传值(View向Controller传值):Action与Action之间的传值. 回顾 ...
- MUI APP关于页面之间的传值,plusready和自定义事件
最近在用MUI开发这个APP,发现有时候这个plusready不起作用,表现在,这个页面如果重复打开,这个plusready就进不去,然后上一个页面传过来的值,就没法接收了.这个经过MUI官方确认,是 ...
- Android开发之Activity的创建跳转及传值
在Android系统的江湖中有四大组件:活动(Activity), 服务(Service), 广播接收器(Broadcast Reciver)和内容提供者(Content Provider).今天所介 ...
- MVC 传值
1.ViewBag Controller:ViewBag.Message = "Hello, Word"; View:@ViewBag.Message 注:View ...
- Java传值和传址
调用函数时,传的参数过去可能是传值,也可能是传址.如果是传值,函数内部的操作对参数的值没有影响:如果是传址,函数内部的操作是对参数指向的内存进行操作,会影响参数的值. Java到底是传值还是传址?用下 ...
- Jquery 页面间传值(非QuerryString)
实现原理: 实现方式不是很复杂,父页面A打开一个子页面 A1,并同时写一个带参数的接收数据函数Receive(result),在A1页面进行逻辑操作,然后调用父页面A的Receive(result)函 ...
- Activity往另外一个Activity传值,Fragment获取另外一个Activity里面的值。
在oneActivity中实现跳转到MainActivity //intent 用来跳转另外一个MainActivity,bundle传值到MainActivity Intent Ma ...
- webform Repeater重复器、地址栏传值、Response
Repeater: 重复器 <HeaderTemplate></HeaderTemplate> - 头模板:在循环开始时,其内容只会打印一遍 <ItemTemplate& ...
随机推荐
- Delphi @ # $ 特殊字符含义
^: 指针 @: 取址 #: 十进制符 $: 十六进制符
- 新手站长选择WordPress程序建站需要注意的8个问题
文章出自:http://www.banwagongvps.com/119.html 如今我们不论是出于个人的兴趣爱好,还是出于我们希望通过搭建自己的网站获利的动机,入门级别的都变得非 常的简单,我们只 ...
- eclipse设置JSP的默认编码
有时候我们新建一个JSP页面,但是编码却不是我们想要的,我们可在eclipse里面进行如下设置: 点击eclipse上面的window-->preferences 输入查找jsp-->点击 ...
- 简单的 Android 拍照并显示以及获取路径后上传
简单的 Android 拍照并显示以及获取路径后上传 Activity 中的代码,我只贴出重要的事件部分代码 public void doPhoto(View view) { destoryBimap ...
- 第六十六节,htnl音频视频
htnl音频视频 学习要点: 1.音频和视频概述 2.video视频元素 3.audio音频元素 本章主要探讨HTML5中音频和视频元素,通过这两个原生的媒体元素向HTML页面 ...
- Stack Overflow for web end
Jquery UI tooltip on disabled button In general, disabled elements do not trigger any DOM events. Th ...
- Sass与Compress实战:第七章
概要:将介绍Compass如何让你从本地开发原型轻松转移到生产环境的网址或Web应用中. 本章内容: ● 生成资源URL的最佳实践 ● 撰写无需Web服务器的样式表 ● 在浏览器中进行设计的技巧 ● ...
- ubuntu环境下docker安装步骤
本文是根据docker官方文档翻译,原文:https://docs.docker.com/engine/installation/linux/ubuntulinux/ Docker 支持以下 Ubun ...
- digitalocean网站打不开,大陆无法正常访问怎么办?
在中国大陆,由于某些恶心的原因,digitalocean官方网站经常出现无法打开,或者打开后网页异常的情况,如果你是一个新注册用户,你甚至会被吓到,一个全球知名的vps主机商网站可能是这样的: 我的天 ...
- .net大型分布式电子商务架构说明(转载来自<头条>)
背景 构建具备高可用,高扩展性,高性能,能承载高并发,大流量的分布式电子商务平台,支持用户,订单,采购,物流,配送,财务等多个项目的协作,便于后续运营报表,分析,便于运维及监控. 架构演变 基础框架剥 ...