i am successful in fetching the current tab url in chrome plugin and i am also able to store it in mysql db using crossdomain ajax. but these all happen only when i click on the plugin is it possible to automate it as soon as tab is changed ?
window.addEventListener("load", windowLoaded, false);
i want to initiate the windowloaded function as soon as the tab is changed.
Just use the chrome.tabs Events google offers. In your case the most appropriate seems the onActiveChanged-Event.
But remember to set the permission in your manifest-file. Otherwise it won’t work.
Also note that this won’t work in content scripts.