The Arcive of vBulletin Modifications Site. |
|
Details »»
|
|||||||||||||||||||||||||
A small addition to prevent members to post long messages wich have no new information, but just long quotes and "Cool!" at the end.
Database Changes: Code:
INSERT INTO setting (settingid,settinggroupid,title,varname,value,description,optioncode,displayorder) VALUES (NULL,'8','Maximum Characters per quote','quotemaxchars','250','The maximum number of characters that you want to allow per quote. Set this to 0 to disable it','','8') Find Code:
$pagetext=htmlspecialchars($postinfo[pagetext]); Code:
$pagetext=$postinfo[pagetext];
$getquote=$DB_site->query_first("SELECT value FROM setting WHERE varname='quotemaxchars'");
$quotemaxchars=$getquote[value];
if (strlen($pagetext) > $quotemaxchars and $quotemaxchars!=0) {
$pagetext = substr($pagetext,0,$quotemaxchars);
$pagetext .= "...";
}
$pagetext=bbcodeparse($pagetext,0,1);
Show Your Support
|
|||||||||||||||||||||||||
| Comments |
|
#2
|
||||
|
||||
|
nice one
thatl come in handy thanks GenSec |
|
#3
|
||||
|
||||
|
This will just stop from posting long messages, not quotes.
|
|
#4
|
|||
|
|||
|
Quote:
It limits not message but size of quotes in it |
|
#5
|
||||
|
||||
|
Limiting posts length is already standard with vBulletin.
Your hack does the exact same thing. |
|
#6
|
|||
|
|||
|
Sorry, it doesn't
Limiting posts length is already standard with vBulletin. Right. If it's limit is 1000 for example and someone post long message with 1000 simbols. Then next replies can look like " Quote:
It's only repeat previous one! I hate it and limited in addition the size of quote to 10% of the max post size. |
|
#7
|
||||
|
||||
|
You are right.
|
|
#8
|
|||
|
|||
|
Ok...now I'm confused
|
|
#9
|
||||
|
||||
|
He's right, I didn't understand it.
![]() Sorry GenSec. |
![]() |
|
|