0
我想從Firefox插件中嵌入Flash對象。你可以從Firefox插件中嵌入Flash內容
這可以用圖片來完成:
imgTest = function(document){
var h = document.getElementsByTagName("body")[0];
var img = document.createElement("img");
img.src = 'chrome://extname/content/image.jpg';
h.appendChild(img);
}
的時候也是使用Flash做的Flash對象不顯示:
flashTest = function(document){
var h = document.getElementsByTagName("body")[0];
var ob = document.createElement("object");
var embed = document.createElement("embed");
embed.type = 'application/x-shockwave-flash';
embed.src = 'chrome://extname/content/flash.swf';
ob.appendChild(embed);
h.appendChild(ob);
}
尋找螢火蟲對象添加數據,但嵌入是變灰了。
這可能嗎?
謝謝。是的,document = wrappedJSObject.document。我已經使用了contentaccessible = yes,我沒有提到它,因爲沒有它的圖像不會顯示。在chrome.manifest中,我有「content extname content/contentaccessible = yes」。 Flash和圖像可以直接訪問,例如。鉻://extname/content/flash.swf。閃光燈和圖像在外部/內容中。既不灰色現在,只有圖像顯示? – user1298511
任何人都可以證實這實際上是可能的 – user1298511