vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Prevent Doubleposting (https://vborg.vbsupport.ru/showthread.php?t=59916)

Taco John 01-09-2004 08:05 PM

I hope this isn't a dumb question... But I just want to make certain I understand this correctly...

This hack is to prevent a user from posting back-to-back messages, correct? And if they do, are they sent anywhere that they are told anything? (ie "doubleposting is turned off, please edit your previous post if you would like to add to your statement, or wait for someone to respond)

If not, It would be a really nice thing to be able to turn it on and off in the admin cp, as well as set a message for users...

Thank you.

Zelda-King 01-09-2004 08:11 PM

If you doublepost, the doublepost is inserted into the previous post as an edit. Thereby, it counts as an edit on a new line rather than as a new post.

Gio Takahashi 01-09-2004 11:18 PM

I installed it and it works.

I have a question, however.

When someone double posts within an hour, how would I make "DOUBLE POST" appear above the second post IE:
Bob:

Hello

Double Post

How are you

Chris M 01-09-2004 11:40 PM

Quote:

Originally Posted by Gio Takahashi
I installed it and it works.

I have a question, however.

When someone double posts within an hour, how would I make "DOUBLE POST" appear above the second post IE:
Bob:

Hello

Double Post

How are you

It has to do with this code:

PHP Code:

   // Update DB
   
$DB_site->query("
    UPDATE " 
TABLE_PREFIX "post
    SET pagetext = '" 
addslashes($doublepost['pagetext'] . "\n\n" $post['message']) . "',
     attach = attach + 
$totalattachments
    WHERE postid = 
$doublepost[postid]
   "
); 

You could simply modify what it sets the pagetext field to, i.e.
Code:

SET pagetext = '" . addslashes($doublepost['pagetext'] . "\n\n" . $post['message']) . "',
becomes
Code:

SET pagetext = '" . addslashes($doublepost['pagetext'] . "\n\n<b>Double Post</b>\n\n" . $post['message']) . "',
I am not sure if that would work exactly, but at 1:39am I am entitled to mistakes :p

Satan

Xenon 01-10-2004 10:54 AM

instead of <b> you have to use [b] but the rest is correct :)

The Keeper 01-10-2004 11:37 AM

One of my moderators just brought this to my attention. Is it possible to have the query which updates a post in the case of a doublepost to also update the post dateline so that users are aware there is new content?

The Keeper 01-10-2004 11:42 AM

Not sure if it's already a feature, but I've managed to edit the code to do this. If anyone wants it, it's fairly simple.

Xenon 01-10-2004 11:47 AM

i will add it to the next version.

be sure you also update the thread/forum's lastpost info if you change the dateline :)

idwf 01-10-2004 11:50 AM

Quote:

Originally Posted by The Quibbler
Great hack! :) *clicks install*

aye...thats a fine hack!

idwf 01-11-2004 03:45 PM

infact...I've changed my mind......that is by FAR the greatest hack Ive ever...EVER seen! Well dont lad! Its saved me no end!


All times are GMT. The time now is 05: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.01278 seconds
  • Memory Usage 1,740KB
  • 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
  • (1)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)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