0

Is it possible to open a website in the current tab when an extension button is clicked instead of open a popup?

This is what I've already try:

{
  "manifest_version": 2,

  "name": "Getting started example",
  "description": "This extension shows a Google Image search result for the current page",
  "version": "1.0",

  "browser_action": {
    "default_icon": "icon.png",
    "default_url": "http.//site.com/"
  },
  "permissions": [
    "activeTab",
    "https://ajax.googleapis.com/"
  ]
}
  • 2
    Possible duplicate of [Google Chrome Extensions - Open New Tab when clicking a toolbar icon](http://stackoverflow.com/questions/3188384/google-chrome-extensions-open-new-tab-when-clicking-a-toolbar-icon) – wOxxOm Nov 20 '15 at 13:01
  • So instead of googling for an existing solution (usually takes a few seconds or a minute) you just invented the imaginary `"default_url"` key? – wOxxOm Nov 20 '15 at 13:01
  • I didn't find any solution!!! –  Nov 20 '15 at 13:03
  • Great! So you did invent the key! Seriously though, simply replace `create` with `update` in the linked duplicate and make sure to read the documentation: https://developer.chrome.com/extensions/ – wOxxOm Nov 20 '15 at 13:04

0 Answers0