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
  #152  
Old 12-21-2004, 07:16 PM
jzewatsky jzewatsky is offline
 
Join Date: Nov 2004
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Where do add the code for showthread.php in vb 3.0.3? I've searched the php several times for the "globalize....." line and have not found it. Thanks in advance for the help.
Reply With Quote
  #153  
Old 12-23-2004, 04:09 PM
bamaster bamaster is offline
 
Join Date: Dec 2004
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Oreamnos
BTW, who has access to this forum on your site? all registered users? special usergroups? admins?

I am just about to install this and just wanted to check what you were doing.

Yes, all registered users. Actually, Registered and Imported users... since I imported my users from phpBB.
Reply With Quote
  #154  
Old 12-23-2004, 04:12 PM
bamaster bamaster is offline
 
Join Date: Dec 2004
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by jzewatsky
Where do add the code for showthread.php in vb 3.0.3? I've searched the php several times for the "globalize....." line and have not found it. Thanks in advance for the help.

Read post #111 in this thread to see the altered code. He said it didn't work for him, but it did for me.
Reply With Quote
  #155  
Old 12-31-2004, 05:43 AM
rushabh rushabh is offline
 
Join Date: Dec 2004
Posts: 22
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi,

I have v3.0.3 too and really cant understand the part about the showthread. Am a beginner in .php so please understand.

What exactly do I find in the showthread and what do I add/replace?

Thanks much

R
Reply With Quote
  #156  
Old 01-05-2005, 08:59 PM
jzewatsky jzewatsky is offline
 
Join Date: Nov 2004
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

bamaster,

Thanks for the suggestion. I tried it (post 111) and am still not working. Would you mind posting exactly how you got it to work? Are we working with different VB ver's?
Reply With Quote
  #157  
Old 01-07-2005, 11:20 AM
MauriceReed MauriceReed is offline
 
Join Date: Dec 2004
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi we have got this hack installed on our forum www.gob++++es.co.uk and it seems to be working fine.

Question, does anybody know what impact, if any, this has on google spiders etc? I have submitted our site to google and some other search engines but vey little evidence of google spiders appearing. On another forum to which I belonged they were regularly visiting.


cheers
Reply With Quote
  #158  
Old 01-28-2005, 03:18 AM
boiboi boiboi is offline
 
Join Date: Nov 2001
Location: san francisco, ca
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

no impact on yahoo whatsover.
Reply With Quote
  #159  
Old 02-14-2005, 01:30 AM
glock22 glock22 is offline
 
Join Date: Feb 2005
Posts: 13
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, I installed the initial code on my 3.0.6 board that I just installed and it worked great.. I thought it was bulletproof... Well , there seems to be a problem. When users are logged in they do not have access to their subscription panel and they cannot use the drop down menu for subscribing to thread or forum. When they click they get a message that they do not have suffiecient privilages etc.... They can read and reply to threads... They cannot use the subsciption.php correctly. I even tried the fix that got posted for the subscription.php.. Still nothing

Nikos

This hack is integral to the success of my forum. ANy help is appreciated.
Reply With Quote
  #160  
Old 02-14-2005, 02:08 AM
glock22 glock22 is offline
 
Join Date: Feb 2005
Posts: 13
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It seems like admin and supermoderators can access the

http://www.vbulletin.com/forum/subscription.php? page

but normal users cannot.. I can't figure it out

Nikos
Reply With Quote
  #161  
Old 02-17-2005, 07:50 AM
boiboi boiboi is offline
 
Join Date: Nov 2001
Location: san francisco, ca
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Strange.. works ok on mine. you shouldn't have edited subscription.php
Reply With Quote
  #162  
Old 03-12-2005, 11:07 PM
Rambo Rambo is offline
 
Join Date: Oct 2003
Location: Scotland, UK
Posts: 58
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Installed on VB 3.0.7 and works a charm

Good job.
Reply With Quote
  #163  
Old 03-30-2005, 12:05 AM
CavGsi.co.uk CavGsi.co.uk is offline
 
Join Date: Dec 2004
Location: Uk
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

When i open the showthread.php i cant find

globalize($_REQUEST, array('perpage' => INT, 'pagenumber', 'highlight' => STR, 'goto'));

Any help please ?? ??
Reply With Quote
  #164  
Old 03-30-2005, 12:06 AM
CavGsi.co.uk CavGsi.co.uk is offline
 
Join Date: Dec 2004
Location: Uk
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CavGsi.co.uk
When i open the showthread.php i cant find

globalize($_REQUEST, array('perpage' => INT, 'pagenumber', 'highlight' => STR, 'goto'));

Any help please ?? ??
am using version 3.0.7
Reply With Quote
  #165  
Old 04-07-2005, 09:26 AM
kadafi_alive kadafi_alive is offline
 
Join Date: Dec 2004
Posts: 146
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by boiboi
no impact on yahoo whatsover.
Exactly, it seems that it's allowing the Googlebot but disallowing [Slurp] Yahoo.
Reply With Quote
  #166  
Old 04-07-2005, 10:58 AM
Onkel_Tom's Avatar
Onkel_Tom Onkel_Tom is offline
 
Join Date: Mar 2002
Location: Stuttgart- Germany
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm using this line:
PHP Code:
preg_match("#(googlebot|slurp@inktomi|yahoo! slurp|lycos|ask jeeves|scooter|fast-webcrawler|turntinbot|msnbot|webcrawler|Infoseek|W3C_Val|Googlebot)#si"$_SERVER['HTTP_USER_AGENT'
and yahoo is working fine
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:03 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.05726 seconds
  • Memory Usage 2,371KB
  • Queries Executed 30 (?)
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
  • (7)bbcode_php
  • (4)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
  • (16)post_thanks_box
  • (16)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (16)post_thanks_postbit_info
  • (15)postbit
  • (16)postbit_onlinestatus
  • (16)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