I have a problem on web intent , when some one click on the follow button then a popup (web intent ) is shown to them, after the user clicks on the follow button I want the popup to close but it’s not closing, can any body help please
here is my code
window.twttr = (function (d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0], t = window.twttr ||
{}; if (d.getElementById(id)) return; js = d.createElement(s); js.id = id; js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs); t._e = []; t.ready = function (f) { t._e.push(f); }; return t;
window.close();
}(document, "script", "twitter-wjs"));
twttr.ready(function (twttr) {
twttr.events.bind('follow', close_popup);
});
function close_popup() {
//Here I want to close the popup when the response come from web intent.
window.close();
}
<a href="http://twitter.com/twitterapi" class="twitter-follow-button" data-show-count="false" data-lang="en">@twitterapi</a>