Thursday, May 5, 2011

Javascript ShareThis Link Disappearing On Postback

Hi, I have a ShareThis (http://www.sharethis.com) link in the footer of my Masterpage. The code they provide generates the link via Javascript. My site is very simple so far (http://www.quotidianword.com), just a place to put your email. But when the email is entered, there is an AJAX postback and the link disappears! Is there any way to prevent this? How do I get the link to reload?

Thanks!

From stackoverflow
  • Ok, so I think I figured it out... It was included in the same UpdatePanel. I took it out of that UpdatePanel and now it works fine. But shouldn't it reload it anyways?

  • Without code sample, I'm not sure--but I would guess you're not running the code after the postback.

    Remember, UpdatePanels still run the whole page lifecycle--Init, Load, PreRender, etc. They only send back the rendered HTML for the particular block of code in the UpdatePanel. Other than that, it acts just as a complete postback does.

0 comments:

Post a Comment

Note: Only a member of this blog may post a comment.