vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Show Thread Enhancements - [AJAX] Post Thank You Hack (https://vborg.vbsupport.ru/showthread.php?t=122944)

w1z4rd 01-29-2007 03:57 AM

Whenever thanks are posted in a gars forum errors occur if the thread spans multiple pages. Any idea how to fix this?

Quote:

Warning: Invalid argument supplied for foreach() in /includes/class_postbit.php(268) : eval()'d code on line 160

Warning: Invalid argument supplied for foreach() in /includes/class_postbit.php(268) : eval()'d code on line 170

brandnewx 01-29-2007 10:35 AM

Does this mod still insert javascript after every post? The last time I checked a few months ago, javascripts were all over the places, tripling page size, which eventually lead to long downloading time plus bad SEO keywords/content ratio.

Abe1 01-29-2007 12:33 PM

Quote:

Originally Posted by ddr (Post 1169195)
i've tried to do so:
Code:

function post_thanks_give_(pid)
{
        fetch_object('post_thanks_button_'+pid).style.display = 'none'
        do_thanks_add = new vB_AJAX_Handler(true)
        do_thanks_add.onreadystatechange(thanks_add_Done)
        do_thanks_add.send('showthread.php?do=post_thanks_add_ajax&p='+pid)
}
function thanks_add_Done() {
        if (do_thanks_add.handler.readyState == 4 && do_thanks_add.handler.status == 200) {
          fetch_object('post_thanks_box_'+manualinsertedpostid).innerHTML = do_thanks_add.handler.responseText+pid
          }
}

i've moved this code to showthread template and cleaned post_thanks_box template. I've also modified all links in hack's templates to use post_thanks_give_('$postid') function, but i couldn't get postid in function thanks_add_Done.
if
Code:

function post_thanks_give_(pid)
{
        fetch_object('post_thanks_button_'+pid).style.display = 'none'
        do_thanks_add = new vB_AJAX_Handler(true)
        do_thanks_add.onreadystatechange(thanks_add_Done(pid))
        do_thanks_add.send('showthread.php?do=post_thanks_add_ajax&p='+pid)
}

function thanks_add_Done(pid) {
        if (do_thanks_add.handler.readyState == 4 && do_thanks_add.handler.status == 200) {
          fetch_object('post_thanks_box_'+pid).innerHTML = do_thanks_add.handler.responseText+pid
          }

}

there is an error
do_thanks_add.handler.readyState is null or non-object

You can pass a variable with onreadystatechange. This is why I would have to use prototype but not sure how now.

Abe1 01-29-2007 12:34 PM

Quote:

Originally Posted by w1z4rd (Post 1169503)
Whenever thanks are posted in a gars forum errors occur if the thread spans multiple pages. Any idea how to fix this?

Use the recounters.

Abe1 01-29-2007 12:35 PM

Quote:

Originally Posted by brandnewx (Post 1169679)
Does this mod still insert javascript after every post? The last time I checked a few months ago, javascripts were all over the places, tripling page size, which eventually lead to long downloading time plus bad SEO keywords/content ratio.

It does right now. I think I may have figured out how to avoid it right now. I have to write it and give it some testing. I was able to do it with a diff prject I am working on.

Lionel 01-29-2007 01:11 PM

Quote:

Originally Posted by Abe1 (Post 1169751)
Use the recounters.

Can you explain please?

w1z4rd 01-29-2007 05:47 PM

Quote:

Originally Posted by Lionel (Post 1169775)
Can you explain please?

Yes please.. I rebuilt nearly everything, still no luck. If there are no thanks recorded for that thread then pages 2 3 etc work fine. As soon as a thanks is inputted and you go past page one the above errors occur.

Lionel 01-29-2007 05:49 PM

I am also very anxious to solve that problem which I mentioned to you months ago. I have been forced to remove all thanks and groans on first post when there are multiple pages on Gars

Abe1 01-29-2007 10:03 PM

Quote:

Originally Posted by w1z4rd (Post 1169945)
Yes please.. I rebuilt nearly everything, still no luck. If there are no thanks recorded for that thread then pages 2 3 etc work fine. As soon as a thanks is inputted and you go past page one the above errors occur.

Could it be getting interfered by another hack?

w1z4rd 01-30-2007 02:41 PM

No because it works fine without gars. This is a great mod just really hoping to clear this up.


All times are GMT. The time now is 01:03 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02561 seconds
  • Memory Usage 1,745KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (5)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete