google chrome extension - How to follow a redirect in Javascript? -
i'm working on chrome extension has conditional context menu. menu should appear if right click on link "youtube.com" hostname.
it works of time, except when using social media facebook or twitter. facebook , twitter redirect internally, causing code not recognize url, , not display context menu. here code looks like:
var contexts = ["selection","frame","page","editable", "link", "video"]; var acceptedurls = ["*://*.youtube.com/*", "*://youtube.com/*","*://*.soundcloud.com/*","*://soundcloud.com/*"]; var title = "add queue"; chrome.contextmenus.create({"title": title, "contexts": contexts, "documenturlpatterns": acceptedurls});
is there way figure out whether url redirect within chrome extension?
Comments
Post a Comment