当前位置:编程问答 > JS >

Flash+Js焦点图切换效果

Flash+Js焦点图切换效果

本文章免费提供一款由Flash+Js焦点图切换效果代码下载哦,这款flash效果的图片切换源码是一款我从网上找到的,现在把源码拿出来给各位朋友看看哦,好了费话不说多了喜欢就把这款焦点图代码下载吧。

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>Flash+Js焦点图切换效果</title>
<script src="js/flash.js" language="javascript"></script>
<style type="text/css">
<!--
.focus {border:1px solid #5B0BB6;background:#fefef3; width:326px;}
-->
</style>
</head>
<body>
<script language="javascript">
 CreateFlash("player", "photo_player.swf", 235, 117, "");
 function getXml() {
  return "<?xml version='1.0' encoding='utf-8'?><root><p u='images/jd1.jpg' a='http://www.zhaoxi.org/' n=''/><p u='images/jd2.jpg' a='http://www.zhaoxi.org/' n=''/><p u='images/jd3.jpg' a='http://www.zhaoxi.org/' n='中国WEB第一站 标题3'/><p u='images/jd4.jpg' a='http://www.zhaoxi.org/' n='中国WEB第一站 标题4'/></root>";
 }
</script>

把下面代码保存成flash.js文件

function CreateFlash(idad, swfurl, wad, had, vs){
var str = "<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="" + wad + "" height="" + had + "" id="" + idad + "" align="middle">";
str += "<param name="allowScriptAccess" value="always">";
str += "<param name="quality" value="high">";
str += "<param name="movie" value="" + swfurl + "">";
str += "<param name="flashvars" value="" + vs + "">";
str += "<embed src="" + swfurl + "" flashvars="" + vs + "" quality="high" width="" + wad + "" height="" + had + "" name="" + idad + "" align="middle" allowScriptAccess="always" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer">";
str += "</object>";
document.write(str);
}

点击下载<a href=http://www.zhaoxi.org/flashjs/photo_player.swf>photo_player.swf</a>文件

</div>
</body>
</html>

补充:网页制作,js教程 
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,