最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - Anchor tag is not working Chrome extension - Stack Overflow

programmeradmin1浏览0评论

i am beginner in field of chrome extension. currently i am making an extension in which i want to open a new page in extension tab on a single click. so this is my code for popup.html

<html>
<head>
<title>Open Google</title>
</head>
<body>
<a href="">Google</a>     
</body>
</html>

google link is working when i opened it as a html page but this is not working in my extension. this is my manifest.json file

{
"manifest_version": 2,
"name": "Open Google",
"version": "1.0",

"browser_action": {
"default_icon": "icon.png",
"default_popup": "popup.html"
},
"permissions": [
"activeTab"
]
}

i am beginner in field of chrome extension. currently i am making an extension in which i want to open a new page in extension tab on a single click. so this is my code for popup.html

<html>
<head>
<title>Open Google</title>
</head>
<body>
<a href="https://google.">Google</a>     
</body>
</html>

google link is working when i opened it as a html page but this is not working in my extension. this is my manifest.json file

{
"manifest_version": 2,
"name": "Open Google",
"version": "1.0",

"browser_action": {
"default_icon": "icon.png",
"default_popup": "popup.html"
},
"permissions": [
"activeTab"
]
}
Share Improve this question edited Mar 10, 2016 at 15:19 Raju VarshnEy asked Mar 10, 2016 at 14:16 Raju VarshnEyRaju VarshnEy 336 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 10

Might this helps you!

<a href="http://www.google." target="_blank">click</a>
发布评论

评论列表(0)

  1. 暂无评论