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

Reply
 
Thread Tools
Disallow guests to view threads, must register first Details »»
Disallow guests to view threads, must register first
Version: 1.00, by Gary King Gary King is offline
Developer Last Online: Jun 2020 Show Printable Version Email this Page

Version: 3.0.0 Rating:
Released: 01-06-2004 Last Update: Never Installs: 89
 
No support by the author.

Yes I know that there is already a a feature to stop guests from viewing threads, but then this also shows all the posts and threads counters to zero, and under Last Post it will say never (which sucks ). But, with my hack, it just asks guests to either login or register when viewing a thread and still shows all the right numbers

Instructions

Open archive/index.php and find
PHP Code:
    $title .= ' - ' $foruminfo['title'];
}
else
{
    
$do 'index';

Below, add
PHP Code:
if ($bbuserinfo['userid'] == AND !preg_match("#(google|slurp@inktomi|yahoo! slurp)#si"$_SERVER['HTTP_USER_AGENT'])) 

    
print_no_permission(); 

Open showthread.php and find
PHP Code:
globalize($_REQUEST, array('perpage' => INT'pagenumber''highlight' => STR'goto')); 
Below, add:
PHP Code:
if ($bbuserinfo['userid'] == AND !preg_match("#(google|slurp@inktomi|yahoo! slurp)#si"$_SERVER['HTTP_USER_AGENT']))
{
    
print_no_permission();

Open template threadbit and find:
PHP Code:
<td class="alt1Active" id="t$thread[threadid]title="$thread[preview]"
Replace it with
PHP Code:
<td class="alt1Active" id="t$thread[threadid]<if condition="$show['member']">title="$thread[preview]"</if>> 
Done!

Show Your Support

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

Comments
  #2  
Old 01-07-2004, 07:49 PM
Amiga-uk Amiga-uk is offline
 
Join Date: Jan 2004
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So.. it makes your forum look REALLY inactive, unless you register? Which you wont, because its not even had a single post in it..

O_o;
Reply With Quote
  #3  
Old 01-07-2004, 08:11 PM
base's Avatar
base base is offline
 
Join Date: Apr 2002
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i think the idea is that the current feature shows 0 threads / posts etc, and this hack shows the correct number of threads / posts, but asks for registration when a user clicks on a thread / post.

this, imo, is better than the current way of going about things, don't know why this isn't how vb did it in the first place
Reply With Quote
  #4  
Old 01-07-2004, 08:52 PM
Amiga-uk Amiga-uk is offline
 
Join Date: Jan 2004
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

^ohh, the current one shows 0 posts..

Right, this is decent then.

Sorry for the misunderstanding ^^;
Reply With Quote
  #5  
Old 01-07-2004, 09:25 PM
C.Birch C.Birch is offline
 
Join Date: Apr 2002
Posts: 459
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i think vb sould do it this way because now guests can infact see how busy your forum is but can not view the topics what means more will become members other then just viewing all your topics has a guest.
Reply With Quote
  #6  
Old 01-07-2004, 10:20 PM
aliencode aliencode is offline
 
Join Date: May 2003
Posts: 31
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Wow nice - woah this really SHOULD be the default hmm wonder what Vbulletin was thinking when they wrote the original.
Reply With Quote
  #7  
Old 01-07-2004, 10:50 PM
Razor-X Razor-X is offline
 
Join Date: Dec 2003
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you for this tip. It was something I had been wanting for a while!
Reply With Quote
  #8  
Old 01-07-2004, 10:52 PM
Zachery's Avatar
Zachery Zachery is offline
 
Join Date: Jul 2002
Location: Ontario, Canada
Posts: 11,440
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

could also be done via a template mod
in a slightly differnt way of course ;D
Reply With Quote
  #9  
Old 01-08-2004, 11:15 AM
Gary King's Avatar
Gary King Gary King is offline
 
Join Date: Jan 2002
Posts: 2,046
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Amiga-uk
So.. it makes your forum look REALLY inactive, unless you register? Which you wont, because its not even had a single post in it..

O_o;
First post edited to clarify things a bit
Reply With Quote
  #10  
Old 01-08-2004, 01:42 PM
eddiec eddiec is offline
 
Join Date: Dec 2001
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thank you!!!
Reply With Quote
  #11  
Old 01-08-2004, 08:33 PM
Razor-X Razor-X is offline
 
Join Date: Dec 2003
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thankyou for the hack-- and it certainly works, but all forums become restricted unless the user is logged-in. Is there a way to make it so you can show the postcount to the restricted forums, but not restrict all the forums? (still allow anonymous access to the other forums).

Thanks
Reply With Quote
  #12  
Old 01-08-2004, 08:44 PM
lange's Avatar
lange lange is offline
 
Join Date: Apr 2003
Location: Montreal (Canada)
Posts: 282
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Razor-X
but all forums become restricted unless the user is logged-in. Is there a way to make it so you can show the postcount to the restricted forums, but not restrict all the forums? (still allow anonymous access to the other forums).

Thanks

I'm looking for that me too.
Reply With Quote
  #13  
Old 01-08-2004, 09:53 PM
gc1 gc1 is offline
 
Join Date: Sep 2002
Posts: 52
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great hack, let's em see all the threads then slams the door in their face if they don't register

Muhahahahahahahahah <Evil Laugh> Damn lurkers annoy me

GC
Reply With Quote
  #14  
Old 01-09-2004, 12:29 AM
trackpads's Avatar
trackpads trackpads is offline
 
Join Date: Aug 2003
Location: Armyville
Posts: 1,074
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Awesome A+++++
Reply With Quote
  #15  
Old 01-11-2004, 12:14 AM
dutchbb dutchbb is offline
 
Join Date: Nov 2003
Posts: 899
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Very good hack tnx! *clicks install*
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 05:13 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.13219 seconds
  • Memory Usage 2,358KB
  • Queries Executed 28 (?)
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
  • (6)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
  • (2)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (15)post_thanks_box
  • (15)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (15)post_thanks_postbit_info
  • (14)postbit
  • (15)postbit_onlinestatus
  • (15)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