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
Details »»

Version: , by Wayne Luke (Senior Member) Wayne Luke is offline
Developer Last Online: Oct 2023 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 06-04-2001 Last Update: Never Installs: 5
 
No support by the author.

Forum Features Hack
---- About
This adds several new options and features to individual forums that can be useful.

New Features
1. Meta Tag Keywords set by forum.
2. Meta Tag Description set by forum.
3. Robot Meta Tag set by forum.

New Options
1. Censor words by Forum.
2. Minimum Posts required for New Thread.
3. Minimum Posts to view Forum.

---- Credits
This hack is distributed under the GPL as an add-on to vBulletin. vBulletin is a commercial product and not subject to this license agreement.

Written by: Wayne Luke
Portions of the Install script written by: Kier Darby
vBulletin is created by Jelsoft Ltd. http://www.jelsoft.com

---- Installation.
Run ff_install.php. This will make the modifications to the database and create the new templates.

Open admin/forum.php and look for:
PHP Code:
  makeyesnocode("Count posts made in this forum towards user post counts?","countposts",1); 
After that add:
PHP Code:
  //WL 04-JUNE-2001 New Forum Features Hack
  
maketableheader("Search Engine Options (v1.2 by Wayne Luke)");
  
maketextareacode("Meta Tag Keywords: ","metakey");
  
maketextareacode("Meta Tag Description","metadesc");
  
makeinputcode("Meta Robot Tag","robotext");

  
maketableheader("Forum Control Options (v1.0 by Wayne Luke)");
  
makeyesnocode("Show in Active Topics?","showactive",1);
  
makeyesnocode("Censor Words in this Forum","censor",1);
  
makeinputcode("Minimum Posts to View","minviewposts");
  
makeinputcode("Minimum Posts to Start New Thread","minposts");
  
//WL End Modification 
Also in admin/forum.php Look for:
PHP Code:
  $DB_site->query("INSERT INTO forum
                      (forumid,styleid,title,description,active,displayorder,parentid,
                       parentlist,allowposting,cancontainthreads,daysprune,newpostemail,newthreademail,
                       moderatenew,allowhtml,allowbbcode,allowimages,allowsmilies,allowicons,
                       styleoverride,allowratings,countposts,moderateattach)
                   VALUES
                      (NULL,'
$styleset','".addslashes($title)."','".addslashes($description)."','$isactive','$displayorder','$parentid',
                       '','
$allowposting','$cancontainthreads','$daysprune','".addslashes($newpostemail)."','".addslashes($newthreademail)."',
                       '
$moderatenew','$aallowhtmlcode','$aallowbbcode','$aallowimgcode','$aallowsmilies','$aallowicons',
                       '
$styleoverride','$allowratings','$countposts','$moderateattach')"); 
Replace with:
PHP Code:
$DB_site->query("INSERT INTO forum
  (forumid,styleid,title,description,active,displayorder,parentid,
   parentlist,allowposting,cancontainthreads,daysprune,newpostemail,newthreademail,
   moderatenew,allowhtml,allowbbcode,allowimages,allowsmilies,allowicons,
   styleoverride,allowratings,countposts,moderateattach,metakey,metadesc,robotext,
   showactive,censor,minviewposts,minposts)
 values (NULL,'
$styleset','".addslashes($title)."','".addslashes($description)."',
         '
$isactive','$displayorder','$parentid','','$allowposting','$cancontainthreads',
         '
$daysprune','".addslashes($newpostemail)."','".addslashes($newthreademail)."',
         '
$moderatenew','$aallowhtmlcode','$aallowbbcode','$aallowimgcode','$aallowsmilies',
         '
$aallowicons','$styleoverride','$allowratings','$countposts','$moderateattach',
         '"
.addslashes($metakey)."','".addslashes($metadesc)."','".addslashes($robotext)."',
         '
$showactive','$censor','$minviewposts','$minposts')"); 
After that add:
PHP Code:
  //WL 04-JUNE-2001 New Forum Features Hack
  
maketableheader("Search Engine Options (v1.2 by Wayne Luke)");
  
maketextareacode("Meta Tag Keywords: ","metakey",$forum[metakey]);
  
maketextareacode("Meta Tag Description","metadesc",$forum[metadesc]);
  
makeinputcode("Meta Robot Tag","robotext",$forum[robotext]);


  
maketableheader("Forum Control Options (v1.0 by Wayne Luke)");
  
makeyesnocode("Show in Active Topics?","showactive",1,$forum[showactive]);
  
makeyesnocode("Censor Words in this Forum","censor",1,$forum[censor]);
  
makeinputcode("Minimum Posts to View","minviewposts",$forum[minviewposts]);
  
makeinputcode("Minimum Posts to Start New Thread","minposts",$forum[minposts]);
  
//WL End Modification 
Last edit in admin/forum.php. Find:
PHP Code:
  $DB_site->query("UPDATE forum
                   SET
                     styleid='
$styleset', title='".addslashes($title)."', description='".addslashes($description)."',
                     active='
$isactive', displayorder='$displayorder', parentid='$parentid', parentlist=$parentlist,
                     allowposting='
$allowposting', cancontainthreads='$cancontainthreads', daysprune='$daysprune',
                     newpostemail='"
.addslashes($newpostemail)."', newthreademail='".addslashes($newthreademail)."',
                     moderatenew='
$moderatenew', allowhtml='$aallowhtmlcode', allowbbcode='$aallowbbcode',
                     allowimages='
$aallowimgcode', allowsmilies='$aallowsmilies', allowicons='$aallowicons',
                     styleoverride='
$styleoverride', allowratings='$allowratings', countposts='$countposts',
                     moderateattach='
$moderateattach'
                   WHERE forumid='
$forumid'"); 
Replace with:
PHP Code:
  $DB_site->query("UPDATE forum
                   SET
                     styleid='
$styleset', title='".addslashes($title)."', description='".addslashes($description)."',
                     active='
$isactive', displayorder='$displayorder', parentid='$parentid', parentlist=$parentlist,
                     allowposting='
$allowposting', cancontainthreads='$cancontainthreads', daysprune='$daysprune',
                     newpostemail='"
.addslashes($newpostemail)."', newthreademail='".addslashes($newthreademail)."',
                     moderatenew='
$moderatenew', allowhtml='$aallowhtmlcode', allowbbcode='$aallowbbcode',
                     allowimages='
$aallowimgcode', allowsmilies='$aallowsmilies', allowicons='$aallowicons',
                     styleoverride='
$styleoverride', allowratings='$allowratings', countposts='$countposts',
                     moderateattach='
$moderateattach', metakey='".addslashes($metakey)."',metadesc='".addslashes($metadesc)."',robotext='".addslashes($robotext)."',
                     showactive='
$showactive',censor='$censor',minviewposts='$minviewposts',minposts='$minposts'
                   WHERE forumid='
$forumid'"); 
In newthread.php find:
PHP Code:
  $smilieson=iif($foruminfo[allowsmilies],$ontext,$offtext); 
After it add:
PHP Code:
  //WL 04-June-2001 Forum Features Hack (v1.0 Wayne Luke)
  
if (($foruminfo[minposts]>$bbuserinfo[posts]) and !(ismoderator($foruminfo[forumid],"",$bbuserinfo[userid])) {
    eval(
"standarderror(\"".gettemplate("error_forumnopost")."\");");
    exit;
  }
  
//WL End Modifications 
In newthread.php find:
PHP Code:
    $subject=censortext($subject);
    
$message=censortext($message); 
Replace with:
PHP Code:
    if ($foruminfo[censor]) {
      
$subject=censortext($subject);
      
$message=censortext($message);
    } 
In Forumdisplay find:
PHP Code:
$smilieson=iif($foruminfo['allowsmilies'],$ontext,$offtext); 
After that add:
PHP Code:
//WL 04-June-2001 Forum Features Hack (v1.0 Wayne Luke)
$keyword=$foruminfo[metakey];
$description=$foruminfo[metadesc];
$robotext=$foruminfo[robotext];

if ((
$foruminfo[minviewposts]>$bbuserinfo[posts]) and !(ismoderator($foruminfo[forumid],"",$bbuserinfo[userid]))) {
  eval(
"standarderror(\"".gettemplate("error_forumnoview")."\");");
  exit;
}
//WL End Modifications 
Finally add the following to your forumdisplay template:
<META NAME="keyword" content="$keyword">
<META NAME="description" content="$description">
<META name="robots" content="$robotext">


These same instructions are included in the readme.txt located in the zip file.

Show Your Support

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

Comments
  #32  
Old 06-16-2001, 04:07 PM
ThomasP
Guest
 
Posts: n/a
Default

Hi,
sounds to be a great hack,
does it work with php3-servers?
thx,
-Tom
Reply With Quote
  #33  
Old 06-26-2001, 01:13 AM
Raptor Raptor is offline
 
Join Date: Nov 2001
Posts: 499
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

very strange

ive installed this to the letter

everything seems perfectly fine BUT

it denies access for new users to EVERY forum (says blah blah you need 0 posts to access)

i have set just one forum to 10 posts to view/new thread and when the newbie gets 10 posts he then has access to ALL the forums with no problems

it also does give the odd few members access to these locked forums when they have only 1 post even though its set to 10

what could possibly be wrong ?
Reply With Quote
  #34  
Old 06-26-2001, 02:36 PM
Christian Christian is offline
 
Join Date: Nov 2001
Location: wuerzburg.germany.earth
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

One question:

In your zip file, which set of files is the right one?

ff_install.php and readme.txt are there each twice!

Once in the root and once in webwork\sitepointforums.com\hacks\forum_features!

AND: they have different file sizes!

Which package is the corect?
Reply With Quote
  #35  
Old 06-26-2001, 03:59 PM
KeithMcL's Avatar
KeithMcL KeithMcL is offline
 
Join Date: Nov 2001
Location: Dublin, Ireland
Posts: 85
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Christian
One question:

In your zip file, which set of files is the right one?

ff_install.php and readme.txt are there each twice!

Once in the root and once in webwork\sitepointforums.com\hacks\forum_features!

AND: they have different file sizes!

Which package is the corect?
I just finished installing great hack and everything went very smoothly. Thanks Wayne.

BTW, Christian the best files to use would be the ones with the latest modified date which is the 06/06/01.

Rgds,
Reply With Quote
  #36  
Old 06-29-2001, 02:04 PM
Raptor Raptor is offline
 
Join Date: Nov 2001
Posts: 499
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Raptor
very strange

ive installed this to the letter

everything seems perfectly fine BUT

it denies access for new users to EVERY forum (says blah blah you need 0 posts to access)

i have set just one forum to 10 posts to view/new thread and when the newbie gets 10 posts he then has access to ALL the forums with no problems

it also does give the odd few members access to these locked forums when they have only 1 post even though its set to 10

what could possibly be wrong ?
*bump*
Reply With Quote
  #37  
Old 07-01-2001, 03:25 PM
Morgo Morgo is offline
 
Join Date: Nov 2001
Posts: 8
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Am I being totally blind, or is the zip file no longer on this thread? Has it been removed?
Reply With Quote
  #38  
Old 07-01-2001, 08:49 PM
Christian Christian is offline
 
Join Date: Nov 2001
Location: wuerzburg.germany.earth
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You are NOT blind!
It is away!
Reply With Quote
  #39  
Old 07-01-2001, 08:54 PM
DeadlyMax
Guest
 
Posts: n/a
Default

where did the zip file go?
Reply With Quote
  #40  
Old 07-01-2001, 10:37 PM
Wayne Luke's Avatar
Wayne Luke Wayne Luke is offline
Senior Member
 
Join Date: Jan 2002
Location: Southern California
Posts: 1,694
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry.. The file must have gotten deleted the last time I tried to update it.

Here is the most up to date file.
Reply With Quote
  #41  
Old 07-02-2001, 03:53 PM
Pingu
Guest
 
Posts: n/a
Default

the install txt in the zip file contains errors.

I got a a parse error on /forumdisplay.php and /admin/forum.php
I replaced the code with the code published on the first post in this thread and things are ok now...
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:06 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.05876 seconds
  • Memory Usage 2,375KB
  • 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
  • (13)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
  • (8)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