Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Minimum posts to use pm's Details »»
Minimum posts to use pm's
Version: 1.00, by Dean C Dean C is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 02-05-2003 Last Update: Never Installs: 11
 
No support by the author.

Minimum posts to use pm's

What does this hack do?

This allows you to have an option in your admin cp where you can define a minimum number of posts that a user must have to use pm's. If the user doesn't have enough posts they will get an error telling them they need so many posts (which you defined in the admin cp) to view the pm's.

Regards

- miSt

Show Your Support

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

Comments
  #32  
Old 03-26-2003, 06:57 PM
Aseerha Aseerha is offline
 
Join Date: Jan 2003
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It didnt work :-(
When i ran that Sql query in PhpMyadmin:
This showed up:

Error

SQL-query :

$DB_site * > query(

"INSERT INTO setting(settingid,settinggroupid,title,varname,val ue,description,optioncode,disp layorder) VALUES (NULL,19,'Minimum Posts','pmminposts','0','Here you define the number of posts a user must have before he/she can use the private message system.','','18')"
)

MySQL said:

You have an error in your SQL syntax near '$DB_site->query("INSERT INTO setting(settingid,settinggroupid,title,varname,val u' at line 1

I'm using Vb 2.2.5
Reply With Quote
  #33  
Old 03-26-2003, 07:05 PM
N9ne N9ne is offline
 
Join Date: Feb 2002
Posts: 1,495
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Run this query instead:

PHP Code:
INSERT INTO setting(settingid,settinggroupid,title,varname,value,description,optioncode,displayorderVALUES (NULL,19,'Minimum Posts','pmminposts','0','Here you define the number of posts a user must have before he/she can use the private message system.','','18'); 
Reply With Quote
  #34  
Old 04-09-2003, 11:39 AM
Dean C's Avatar
Dean C Dean C is offline
 
Join Date: Jan 2002
Location: England
Posts: 9,071
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

*updated installation instructions*

- miSt
Reply With Quote
  #35  
Old 04-09-2003, 12:37 PM
Oblivion Knight's Avatar
Oblivion Knight Oblivion Knight is offline
 
Join Date: May 2002
Location: Sheffield, UK
Posts: 1,757
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thankyou very much Mist,
Very useful hack so that people don't register just to send advertisements about their site via PM..

One thing you may want to update in your instructions though..

Code:
Find in private.php:

----------------------------

require ("./global.php");

----------------------------
Should be:

Code:
Find in private.php:

----------------------------

require("./global.php");

----------------------------
(There's no space between the "e" from require and the opening bracket "(").

[high]* Oblivion Knight clicks install.[/high]
Reply With Quote
  #36  
Old 04-09-2003, 12:56 PM
Dean C's Avatar
Dean C Dean C is offline
 
Join Date: Jan 2002
Location: England
Posts: 9,071
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

*updated installation instructions again*

- miSt
Reply With Quote
  #37  
Old 09-02-2003, 09:47 PM
FWF FWF is offline
 
Join Date: Feb 2003
Location: Indianapolis, IN
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this is VERY helpful

*installs*
Reply With Quote
  #38  
Old 11-29-2003, 03:13 PM
Thomas P's Avatar
Thomas P Thomas P is offline
 
Join Date: Oct 2001
Location: Munich, DE
Posts: 365
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great hack, easy and simple and works for vb 2.3.3

To add this functionality for the eMail feature, too, add this to member.php

Look for this:

Code:
  if (!$bbuserinfo['userid'] or $bbuserinfo['usergroupid']==3) {
    //don't let people awaiting email confirmation use it either as their email may be fake
    show_nopermission();
  }
add below

Code:
  if ($bbuserinfo[posts] < $pmminposts) {
   eval("standarderror(\"".gettemplate("error_pmminposts")."\");");
  }
Edit the template to reflect the change:

Sorry you need to have $pmminposts posts before you can use the private message system or the email function.


That's it
Reply With Quote
  #39  
Old 12-12-2003, 12:44 AM
Thomas P's Avatar
Thomas P Thomas P is offline
 
Join Date: Oct 2001
Location: Munich, DE
Posts: 365
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm, how to prevent other users from sending them a PN?
Reply With Quote
  #40  
Old 02-16-2004, 03:32 PM
Thomas P's Avatar
Thomas P Thomas P is offline
 
Join Date: Oct 2001
Location: Munich, DE
Posts: 365
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Thomas P
Hmm, how to prevent other users from sending them a PN?
^^^moderate bump

>Hmm, how to prevent other users from sending them a PN?
Reply With Quote
  #41  
Old 03-06-2004, 11:21 AM
Thomas P's Avatar
Thomas P Thomas P is offline
 
Join Date: Oct 2001
Location: Munich, DE
Posts: 365
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Thomas P
^^^moderate bump

>Hmm, how to prevent other users from sending them a PN?
Nevermind, I placed a.m. code in the member.php where the sending mechanism is, so people can read and do stuff, but don't send.
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 11:09 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.08350 seconds
  • Memory Usage 2,311KB
  • Queries Executed 25 (?)
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
  • (3)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