I have a Crossrider extension which pops up a menu with a PNG image (in popup.html) when the extension icon is clicked. This works fine. But I also want to open popup.html in the same way when the user enters certain URL patterns (this part is also already working). Nothing I've tried for the last few hours works. Help! Extension ID: 83484
In background.js I have this:
appAPI.browserAction.setPopup(
{
resourcePath: 'popup.html',
height: popupDims[ appAPI.platform ].height,
width: popupDims[ appAPI.platform ].width
});
In extension.js I have this:
appAPI.openURL(
{
resourcePath: "popup.html",
where: "window",
focus: true,
focusTimer: 5000,
height: 300,
width: 300
});
I've also used "popup" instead of "window".
The popup.html window / popup doesn't display an image that's referenced in the file, even though the image is present in the popup that displays when I click on the extension icon. Also, the links work when the popup is displayed after an icon click, but not in the code above.