使用YouTube API的IE8中出现“预期对象”错误

问题描述

| IE8中出现了一些问题,其中包含一些使用Data API来显示YouTube视频的JavaScript。 我收到的错误是\'Object Expected \',这是第二行代码引起的。
// <![CDATA[
var baseUrl = \'http://www.youtube.com/\';
var swfUrl = constructUrl(baseUrl);

// allowScriptAccess must be set to allow the Javascript from one
// domain to access the swf on the youtube domain
var params = { allowScriptAccess: \"always\",bgcolor: \"#cccccc\" };

// This sets the ID of the DOM object or embed tag to \'myytplayer\'.
// You can use this ID to access the swf and call the player\'s API
var atts = { id: \"myytplayer\" };
var flashvars = {};
swfobject.embedSWF(swfUrl,\"ytapiplayer\",\"220\",\"125\",\"9\",null,flashvars,params,atts);
//]]>
有没有人遇到此错误,您是否有经过测试的解决方案?     

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)