网络编程 | 站长之家 | 网页制作 | 图形图象 | 操作系统 | 冲浪宝典 | 软件教学 | 网络办公 | 邮件系统 | 网络安全 | 认证考试 | 系统进程
Firefox | IE | Maxthon | 迅雷 | 电驴 | BitComet | FlashGet | QQ | QQ空间 | Vista | 输入法 | Ghost | Word | Excel | wps | Powerpoint
asp | .net | php | jsp | Sql | c# | Ajax | xml | Dreamweaver | FrontPages | Javascript | css | photoshop | fireworks | Flash | Cad | Discuz!
当前位置 > 网站建设学院 > 网络编程 > ASP技巧
Tag:注入,存储过程,分页,安全,优化,xmlhttp,fso,jmail,application,session,防盗链,stream,无组件,组件,md5,乱码,缓存,加密,验证码,算法,cookies,ubb,正则表达式,水印,索引,日志,压缩,base64,url重写,上传,控件,Web.config,JDBC,函数,内存,PDF,迁移,结构,破解,编译,配置,进程,分词,IIS,Apache,Tomcat,phpmyadmin,Gzip,触发器,socket
网络编程:ASP教程,ASP.NET教程,PHP教程,JSP教程,C#教程,数据库,XML教程,Ajax,Java,Perl,Shell,VB教程,Delphi,C/C++教程,软件工程,J2EE/J2ME,移动开发
本月文章推荐
.用ASP+DLL实现WEB方式修改服务器.
.判断Cookies是否处于开启状态.
.谈谈如何在不支持数据库的asp主页.
.用VB6读写数据库中的图片.
.不用组件来实现StrCat函数的功能.
.ASP出错集成处理.
.ASP中使用Session变量的优缺点.
.生成像资源管理器一样的树形目录.
.服务器获得客户端时间的方法.
.ASP动态生成的javascript表单验证.
.拦截表单的另外一种写法.
.防护手册:如何防止ASP木马在服务.
.用HTML框架减少服务器流量.
.一个普通的数据库例子源源程序.
.remote script文档(转载自微软)(.
.系统时间格式问题而导致BLOG不正.
.通过asp入侵web server,窃取文件.
.asp实现关键词获取(各搜索引擎,g.
.设计 FileSystemObject.
.ASP.NET连SQL7接口源代码.

用ASP控制Flash

发表日期:2001-2-6


Controlling Flash with ASP

A recent project has required a few things that I haven't done for a while. One is dealing with Flash -
which I haven't done since shortly after the release of Flash 3.0. The other is to actually figure some
way of getting dynamic content in without using Generator. One solution we've come up with involves
jumping out of a flash movie into an ASP page, then back again. Of course our designers were a little
miffed, since they've built the flash movie with all sorts of different transitions from place to place,
and this solution would mean starting from the opening scene of the movie evry time. It also stank from a
usability standpoint.

Not so, said I

To accomplish the effect of jumping back in at a specific frame, we simply load some variables into the
flash movie and use them to jump to the right frame. Cool huh?

Initially we had a little trouble, since designers don't need to know anything about ASP, so conveying
information back and forth was a little tricky, but we got there. How it works is like this

In the flash Movie, the first frame has a piece of actionscript which simply reads

GoToAndPlay(scene);
Stop();
The syntax is slightly different in Flash 4.0 - this is Flash 5.0, but you get my drift

Now, when jumping back from the ASP page to the Flash page, we tag a querystring parameter onto the links

flash.asp?scene=awards
flash.asp?scene=services
flash.asp?scene=contact
And so on. The script flash.asp looks something like this...

<%@Language="JScript"%><%
Response.Buffer = true; Response.Expires = -1441;
var s = new String(Request.Querystring("scene"));
strScene = (s!='undefined'&&s!='')?s:'default';
%><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Flash Control</title>
</head>
<body>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0"
width="750" height="395">
<param name="movie" value="movie.swf?scene=<%= strScene %>">
<param name="quality" value="high">
<embed src="movie.swf?scene=<%= strScene %>" quality="high"
pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?
P1_Prod_Version=ShockwaveFlash"
type="application/x-shockwave-flash" width="750" height="395">
</embed>
</object>
</body>
</html>
So, if we have nothing in the querystring, it loads the scene 'default' - else it loads whatever ASP tells
it to. cool huh?

This trick will work from Flash 4.0 upwards - flash 5.0 is particularly nifty, and i could get to like
it...
上一篇:较长text型数据无法在Asp页面中取出的解决办法 人气:9802
下一篇:计算ASP页面的载入时间 人气:11589
浏览全部的内容 Dreamweaver插件下载 网页广告代码 祝你圣诞节快乐 2009年新年快乐