Thanks for this snippet. It is doing fine, even in IE.
Although it took me hours to find out that the Web Intent functionality already opens the popup.
But the problem with this code is, that the text-parameter is entirely fix. This is rarely the case in dynamic web projects.
Many sites have a textarea, where the user writes some text and is supposed to hit the “tweet”-button afterwards.
So, the link is still to be assembled by the developer!
My solution was to put the link together and change the href ON BLUR of the textarea.
It would be great if you could keep this procedure in mind when developing the API.