That's great Jesse that you've found a method that works. I didn't
know that was a way to force a reload of widget.js.

Note that widget.js only needs to be re-sourced once to render all
Tweet buttons on the page, so you can just render plain tweet links
and then re-source the script.

An alternative method I've found successful is to take a local copy of
widget.js and give its main function a name:

  var twttr=window.twttr||{};(twttr.showWidgets = function()...

(Note that the parenthesis and the end has to be moved before the

The AJAX response can the just include a "twttr.showWidgets()" call.

Twitter should really alter widget.js to do something similar, just
like the Facebook sharer allows you to call "FB.Share.renderPass()".

Another alternative that should work, but doesn't, probably because of
a Twitter bug, is to render the button directly as an iframe, as
described at . AJAX updates
then work fine, except for a JavaScript error about a missing
twttr.updateTweetCount function. Is this a bug in ?


Twitter developer documentation and resources:
API updates via Twitter:
Issues/Enhancements Tracker:
Change your membership to this group:

Reply via email to