swfobject undefined即嵌入youtube视频时

时间:2012-04-05 13:53:13

标签: internet-explorer youtube swfobject

我有一个似乎无法解决的问题 我有这个网站http//:makeandsee.com/shadow.html

它从单个YouTube用户中提取所有YouTube视频并显示它们,除了IE之外,所有浏览器都能正常运行。在IE中,它会抛出一个错误,说swfobject没有定义,这没有任何意义,因为所有其他浏览器都没有任何问题的建议吗?

1 个答案:

答案 0 :(得分:0)

您是否可以使用Javascript访问swfobject?并且做这样的事情?

function getFlashMovieObject(movieName){
    if (window.document[movieName]){
        return window.document[movieName];
    }
    if (navigator.appName.indexOf("Microsoft Internet")==-1){
        if (document.embeds && document.embeds[movieName])
            return document.embeds[movieName];
    }
    else{
        return document.getElementById(movieName);
    }
}
相关问题