謝謝!我剛剛下載了一個Hello World樣本文件,並意識到它只是一個HTML和JS腳本。可以將popup.php替換爲Google擴展程序中的popup.html嗎?
我可以用popup.php替換popup.html幷包含PHP代碼嗎?
謝謝!
謝謝!我剛剛下載了一個Hello World樣本文件,並意識到它只是一個HTML和JS腳本。可以將popup.php替換爲Google擴展程序中的popup.html嗎?
我可以用popup.php替換popup.html幷包含PHP代碼嗎?
謝謝!
但我將能夠導入一個js文件訪問我的服務器,這是最好的解決方案嗎? –
是的。我更喜歡注入Iframe並使用JavaScript加載內容。 –
更容易(對我來說)!好主意問,謝謝! –
你可以用iframe和遠程popup.php使它]
這裏是我的popup.php:
<html>
<head>
<title>Example Project</title>
</head>
<body>
<center><h1>Project: Example</h1>
<h3>Under Construction</h3>
<img src="<?= 'http://myvegaslimo.com/images/simpsons-under-construction.jpg' ?>" alt="under construction"></img></center>
</body>
</html>
這裏是popup.html:
<iframe src="http://example.com/chrome-extension/Example/popup.php" width="640" height="580" style="border:none;"></iframe>
不。它必須是一個HTML文件。 –