I have an addon that open a html page when you click a button on the browser bar (so far so good)
in the html page I have this javascript:
function new_version_show_window()
{
if (prefManager.getCharPref("extensions.mf_unblocker.blocker_version_in_prefs") != this_version)
{
gBrowser.selectedTab = gBrowser.addTab("http://mfre.com/mf/new_install_'+this_version+'.html");
}
}
But I am getting the error:
gBrowser is undefined
The javascript is in
chrome://mf_unblocker/content/0_register.html
so I am very much still in the browser extension
how do i get it to open a new tab?
Thanks!
Ryan
Try this:
Assuming url is the URL to be opened