Abe,
I'm trying to get the postbit template to refresh as well upon thanking a post (in order to update the "Thanked 4 Times in 4 Posts" text...
Within post_thanks.js I have modified function
thanks_add_done() by adding an additional fetch_object (to call the respective postbit) as follows:
PHP Code:
function thanks_add_Done()
{
if (do_thanks_add.handler.readyState == 4 && do_thanks_add.handler.status == 200)
{
fetch_object('td_post_' + do_thanks_add.postid).innerHTML = do_thanks_add.handler.responseText;
fetch_object('post_thanks_box_' + do_thanks_add.postid).innerHTML = do_thanks_add.handler.responseText;
}
}
Unfortunately, I'm pretty new at JS so it doesn't work. Any ideas what I am doing wrong and how to get it to refresh the respective postbit?