首页 新闻 会员 周边 捐助

Flash文件播放,怎么全屏?

0
悬赏园豆:30 [已解决问题] 解决于 2013-09-15 16:11
<script src="/js/swfobject.js" type="text/javascript"></script>
//file为播放文件,如xiyouji.swf,sanguoyanyi.swf
var so = new SWFObject(file, "swf1", "500", "400", "9", "#FFFFFF");
        so.addVariable("variable1", getQueryParamValue("variable1"));
        so.addVariable("variable2", getQueryParamValue("variable2"));
        so.write("flashcontent");

由于播放文件中还有播放器?怎么设置全屏啊?

学之乐的主页 学之乐 | 初学一级 | 园豆:33
提问于:2013-09-14 14:28
< >
分享
最佳答案
0

试试:

var so = new SWFObject(file, "swf1", "100%", "100%", "9", "#FFFFFF");
so.addParam("allowFullScreen", "true");
so.addParam("wmode", "window");
so.write("flashcontent");
收获园豆:30
dudu | 高人七级 |园豆:30939 | 2013-09-14 15:05

不行啊!不起作用!

学之乐 | 园豆:33 (初学一级) | 2013-09-14 15:23

@学之乐: 

试试下面的代码:

var swfobjec = new SWFObject();
var flashvars = {};
var params = { scale: "exactFit" };
var attributes = {};
swfobject.embedSWF("mymovie.swf", "flashcontent", "100%", "100%", "7", false, flashvars, params, attributes);

参考自:100% Width and Height in Browser

dudu | 园豆:30939 (高人七级) | 2013-09-14 15:27
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册