1
this.window.location.href
工作是不是在HTML文件浏览器扩展程序 工作我试图在脚本中此功能:window.location.href无法在Chrome扩展
function myFunction()
{
var pl = this.window.location.href;
var sWords= localStorage.getItem(pl);
document.write(pl);
}
,这让我:
chrome-extension://ebeadbfnnghmakkbimckpdmocjffkbjc/popup.html
所以我应该做什么来获得页面的链接?
的可能重复[如何得到我的页面动作弹出当前打开的选项卡上的网址是什么?(http://stackoverflow.com/questions/10413911/how-to-get-the-currently -opened-tabs-url-in-my-page-action-popup) –
@RobW链接删除..谢谢指针..对不起... – ManseUK