我又有新问题了,大伙帮忙看看

accp2008lx 2008-11-11 04:23:18
是这样的,我想在页面中显示一个Flash,不知道要什么条件才能成立,特向各位请教!
...全文
90 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
accp2008lx 2008-11-12
  • 打赏
  • 举报
回复
楼上的,在dreamweaver上使用的确是可行,但我把dreamweaver设计器的代码加载到asp.net中的时候,代码又行不通了,一运行,就是一片空白,啥都没有。

再劳烦一下各位,看看是不是还有什么要注意的!

3楼和5楼的方法我都试过了。都是同样的问题,运行出来的页面是空白的!
adoxcy 2008-11-11
  • 打赏
  • 举报
回复
ctrl+Alt+F把flash嵌入进来就行
accp2008lx 2008-11-11
  • 打赏
  • 举报
回复
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default3.aspx.cs" Inherits="Default3" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>无标题页</title>

<script type="text/javascript">
var pic_width=266; //图片宽度
var pic_height=184; //图片高度
var button_pos=4; //按扭位置 1左 2右 3上 4下
var stop_time=3000; //图片停留时间(1000为1秒钟)
var show_text=0; //是否显示文字标签 1显示 0不显示
var txtcolor="000000"; //文字色
var bgcolor="DDDDDD"; //背景色
var imag=new Array();
var link=new Array();
var text=new Array();
imag[1]="images/01.jpg";
link[1]="#";
text[1]="标题 1";
imag[2]="images/02.jpg";
link[2]="#";
text[2]="标题 2";
imag[3]="images/03.jpg";
link[3]="#";
text[3]="标题 3";
imag[4]="images/04.jpg";
link[4]="#";
text[4]="标题 4";
imag[5]="images/05.jpg";
link[2]="#";
text[5]="标题 5";
//可编辑内容结束
var swf_height=show_text==1?pic_height+20:pic_height;
var pics="", links="", texts="";
for(var i=1; i<imag.length; i++){
pics=pics+("|"+imag[i]);
links=links+("|"+link[i]);
texts=texts+("|"+text[i]);
}
pics=pics.substring(1);
links=links.substring(1);
texts=texts.substring(1);
document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cabversion=6,0,0,0" width="'+ pic_width +'" height="'+ swf_height +'">');
document.write('<param name="movie" value="Images/BANNER设计.swf">');
document.write('<param name="quality" value="high"><param name="wmode" value="opaque">');
document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&pic_width='+pic_width+'&pic_height='+pic_height+'&show_text='+show_text+'&txtcolor='+txtcolor+'&bgcolor='+bgcolor+'&button_pos='+button_pos+'&stop_time='+stop_time+'">');
document.write('<embed src="Images/BANNER设计.swf" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&pic_width='+pic_width+'&pic_height='+pic_height+'&show_text='+show_text+'&txtcolor='+txtcolor+'&bgcolor='+bgcolor+'&button_pos='+button_pos+'&stop_time='+stop_time+'" quality="high" width="'+ pic_width +'" height="'+ swf_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
document.write('</object>');
</script>

</head>
<body>
<form id="form1" runat="server">
<div>

</div>
</form>
</body>
</html>
这是我的页面代码,然后运行,页面一片空白,啥都没有..!
jiang_jiajia10 2008-11-11
  • 打赏
  • 举报
回复
我发的随意可以放,那都能放
accp2008lx 2008-11-11
  • 打赏
  • 举报
回复
这是在<head></head>中添加的代码,我想问一下,在<body></body>就该如何编写代码!
jiang_jiajia10 2008-11-11
  • 打赏
  • 举报
回复

<script type=text/javascript>
var pic_width=266; //图片宽度
var pic_height=184; //图片高度
var button_pos=4; //按扭位置 1左 2右 3上 4下
var stop_time=3000; //图片停留时间(1000为1秒钟)
var show_text=0; //是否显示文字标签 1显示 0不显示
var txtcolor="000000"; //文字色
var bgcolor="DDDDDD"; //背景色
var imag=new Array();
var link=new Array();
var text=new Array();
imag[1]="images/01.jpg";
link[1]="#";
text[1]="标题 1";
imag[2]="images/02.jpg";
link[2]="#";
text[2]="标题 2";
imag[3]="images/03.jpg";
link[3]="#";
text[3]="标题 3";
imag[4]="images/04.jpg";
link[4]="#";
text[4]="标题 4";
imag[5]="images/05.jpg";
link[2]="#";
text[5]="标题 5";
//可编辑内容结束
var swf_height=show_text==1?pic_height+20:pic_height;
var pics="", links="", texts="";
for(var i=1; i<imag.length; i++){
pics=pics+("|"+imag[i]);
links=links+("|"+link[i]);
texts=texts+("|"+text[i]);
}
pics=pics.substring(1);
links=links.substring(1);
texts=texts.substring(1);
document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cabversion=6,0,0,0" width="'+ pic_width +'" height="'+ swf_height +'">');
document.write('<param name="movie" value="images/focus.swf">');
document.write('<param name="quality" value="high"><param name="wmode" value="opaque">');
document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&pic_width='+pic_width+'&pic_height='+pic_height+'&show_text='+show_text+'&txtcolor='+txtcolor+'&bgcolor='+bgcolor+'&button_pos='+button_pos+'&stop_time='+stop_time+'">');
document.write('<embed src="images/focus.swf" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&pic_width='+pic_width+'&pic_height='+pic_height+'&show_text='+show_text+'&txtcolor='+txtcolor+'&bgcolor='+bgcolor+'&button_pos='+button_pos+'&stop_time='+stop_time+'" quality="high" width="'+ pic_width +'" height="'+ swf_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
document.write('</object>');
</script>

弄上去吧
accp2008lx 2008-11-11
  • 打赏
  • 举报
回复
很感谢楼上兄弟的代码,但很可惜,显示不出来!是不是还有一些地方需要注意的!
luoyinshuang 2008-11-11
  • 打赏
  • 举报
回复
把这个嵌入到你的页面代码

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="628" height="120">
<param name="movie" value="文件路径" />
<param name="quality" value="high" />
<embed src="文件路径" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="628" height="120"></embed>
</object>
accp2008lx 2008-11-11
  • 打赏
  • 举报
回复
是在页面上放一个Flash,不需要播放器的,就是那种动态图片Flash!
atpains 2008-11-11
  • 打赏
  • 举报
回复
客服端安装了FLASH 播放器 就可以拉。

62,046

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术交流专区
javascript云原生 企业社区
社区管理员
  • ASP.NET
  • .Net开发者社区
  • R小R
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

.NET 社区是一个围绕开源 .NET 的开放、热情、创新、包容的技术社区。社区致力于为广大 .NET 爱好者提供一个良好的知识共享、协同互助的 .NET 技术交流环境。我们尊重不同意见,支持健康理性的辩论和互动,反对歧视和攻击。

希望和大家一起共同营造一个活跃、友好的社区氛围。

试试用AI创作助手写篇文章吧