Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > General > Member Archives
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Doublepost = Not counted in user's post count Details »»
Doublepost = Not counted in user's post count
Version: , by Austin Dea Austin Dea is offline
Developer Last Online: Oct 2005 Show Printable Version Email this Page

Version: Unknown Rating:
Released: 08-22-2002 Last Update: Never Installs: 0
 
No support by the author.

We all know that sometimes there is a need to post a couple times in a row, whether it be multiple attachments, posting updates, etc. This hack will make it so that the double/triple/whatever post is not added to the user's post count, but still shown and updated in the forum and thread count. I kow at some boards there is a lot of competition in post counts, and although doubleposting is not looked highly upon in most forums, this would ensure that the user isn't getting any benefit out of it. Plus people could use it for bumping topics, etc, etc, etc. This hack will also make it so if that doublepost is deleted, it will not subtract from the user's postcount. Since it was never added in the first place, it shouldn't be a problem .

---------------------------------------------------------------------
NOTE: I did use (with permission) the query and if statement from Xenon's Prevent Doubleposting hack.
---------------------------------------------------------------------

This is a simple hack which only involves 2 file edits (editpost.php and newreply.php). And it does work with the QRB =P. If you have any questions, etc, post them here.


DOESN'T WORK.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #32  
Old 08-23-2002, 06:18 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

you can use it, but it's not perfect
or as g-force said: not perfect in MY opinion
Reply With Quote
  #33  
Old 08-23-2002, 06:19 PM
Austin Dea's Avatar
Austin Dea Austin Dea is offline
 
Join Date: Dec 2001
Location: Denver, CO, USA
Posts: 342
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't think dates and stuff should matter. By double posting, I mean just that someone has two posts in a row. Not they clicked the link twice or whatever.
Reply With Quote
  #34  
Old 08-23-2002, 06:27 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok, but do I need it? Do I need anything in the newreply.php? Will the hack work ok for the count without it? I think I have a way of taking care of the attachment problem. I just won't allow you to add an attachment if it is a double post. Will that work?

Quote:
Originally posted by Xenon
you can use it, but it's not perfect
or as g-force said: not perfect in MY opinion
Reply With Quote
  #35  
Old 08-23-2002, 06:32 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yes it'll work
no you don'T NEED some extra changes to newreply.php after using g-forces
Reply With Quote
  #36  
Old 08-23-2002, 06:39 PM
Austin Dea's Avatar
Austin Dea Austin Dea is offline
 
Join Date: Dec 2001
Location: Denver, CO, USA
Posts: 342
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, part of the point of this hack was to make it so people could do multiple attachments, only without adding onto their post count.
Reply With Quote
  #37  
Old 08-23-2002, 06:45 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

then you should take out the attachement conditions from my editpost.php part
Reply With Quote
  #38  
Old 08-23-2002, 06:45 PM
Austin Dea's Avatar
Austin Dea Austin Dea is offline
 
Join Date: Dec 2001
Location: Denver, CO, USA
Posts: 342
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Why would this not work?

PHP Code:
        $postcounted="";
            if (
$threadinfo[lastposterid]!=$bbuserinfo[userid]) {
                
$postcounted="1";
            } else {
                
$postcounted="0";
            }
          
$DB_site->query("UPDATE user SET
          "
.iif ($foruminfo[countposts],"posts=posts+$postcounted,","")."
          
$dotitle"."lastpost='".time()."' WHERE userid='$bbuserinfo[userid]'"); 
Instead of the iif()'s g-force had.
Reply With Quote
  #39  
Old 08-23-2002, 06:47 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

g-force2k2, this is the line I have in my newreply.php that I need to replace.

Code:
".iif ($foruminfo[countposts], incrementposts($bbuserinfo['userid']), '')."
How do I replace it with the following?

Code:
// doublepost = no count hack 
".iif ($foruminfo[countposts],"posts=posts+'".iif($threadinfo[lastposter] == "$bbuserinfo[username]",'0','1')."',","")."
// end doublepost = nocount hack
Reply With Quote
  #40  
Old 08-23-2002, 06:48 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it would work, but iif looks better
Reply With Quote
  #41  
Old 08-23-2002, 08:42 PM
Austin Dea's Avatar
Austin Dea Austin Dea is offline
 
Join Date: Dec 2001
Location: Denver, CO, USA
Posts: 342
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Boofo
g-force2k2, this is the line I have in my newreply.php that I need to replace.

Code:
".iif ($foruminfo[countposts], incrementposts($bbuserinfo['userid']), '')."
How do I replace it with the following?

Code:
// doublepost = no count hack 
".iif ($foruminfo[countposts],"posts=posts+'".iif($threadinfo[lastposter] == "$bbuserinfo[username]",'0','1')."',","")."
// end doublepost = nocount hack
Is incrementposts() a functions in your functions.php? If so, you'd need to edit that function...
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:54 PM.


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.04893 seconds
  • Memory Usage 2,333KB
  • Queries Executed 26 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (4)bbcode_code
  • (1)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete