⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 javascript_to_flash.html

📁 javascript和flash的通信
💻 HTML
字号:
<HTML>
<HEAD>
<TITLE>javascript_to_flash</TITLE>
</HEAD>
<SCRIPT LANGUAGE=JavaScript>
<!--
function doPassVar(args){
	var sendText = args.value;
	window.document.myFlash.SetVariable("myVar", sendText);
}
//-->
</SCRIPT> 
<BODY bgcolor="#FFFFFF">
<p><b><font face="Geneva, Arial, Helvetica">Example of JavaScript-to-Flash communication</font></b> 
</p>
<p><font face="Geneva, Arial, Helvetica">Enter some text in the HTML form field 
  below and then click outside the field, or hit the Tab key, to send the text 
  to the Flash movie below:</font></p>
<form name="form1" onSubmit="doPassVar(sendText);" action="#">
  <input type="text" name="sendText" maxlength="45" onChange="doPassVar(this);">
</form>
<p><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"
 width=400 height=180 id="myFlash">
    <param name=movie value="javascript_to_flash.swf">
    <param name=quality value=high>

    <embed src="javascript_to_flash.swf" quality=high width=400 height=180 type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" name="myFlash" swLiveConnect="true">
    </embed> 
  </object></p>
</BODY>
</HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -