Track if tweet button pressed in popup window (web intents)

webintent
api

#1

I am using the following code to open a popup window that leads to an intent. However i can only track the event when the window closes. Is there a way at the momemt to track when a user presses the “Tweet” Button?

I read there was a postMessage event that is no longer working?

function TweetPopUp() {
    $(".twitter-share-link").on("click", function(e){
      e.preventDefault();
      intent = $(this).attr("href"); // pre-built link of web intent
      var win = window.open(intent, 'twitter','width=1000,height=420,status=0,toolbar=0');

      var timer = setInterval(function() {
          if(win.closed) {
              clearInterval(timer);
              alert('closed');
          }

      }, 1000);
    });
  }

#2

No event is fired in response to a newly published or submitted Tweet.


#3

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.