vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Disallow guests to view threads, must register first (https://vborg.vbsupport.ru/showthread.php?t=59859)

Gary King 01-06-2004 10:00 PM

Disallow guests to view threads, must register first
 
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 :D

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! :D

Amiga-uk 01-07-2004 07:49 PM

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;

base 01-07-2004 08:11 PM

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 :)

Amiga-uk 01-07-2004 08:52 PM

^ohh, the current one shows 0 posts..

Right, this is decent then.

Sorry for the misunderstanding ^^;

C.Birch 01-07-2004 09:25 PM

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.

aliencode 01-07-2004 10:20 PM

Wow nice - woah this really SHOULD be the default hmm wonder what Vbulletin was thinking when they wrote the original.

Razor-X 01-07-2004 10:50 PM

Thank you for this tip. It was something I had been wanting for a while!

Zachery 01-07-2004 10:52 PM

could also be done via a template mod :)
in a slightly differnt way of course ;D

Gary King 01-08-2004 11:15 AM

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 :)

eddiec 01-08-2004 01:42 PM

thank you!!!

Razor-X 01-08-2004 08:33 PM

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

lange 01-08-2004 08:44 PM

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.

gc1 01-08-2004 09:53 PM

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

trackpads 01-09-2004 12:29 AM

Awesome A+++++

dutchbb 01-11-2004 12:14 AM

Very good hack tnx! *clicks install*

trackpads 01-11-2004 12:47 AM

Is there a way to disable this for a specific forum? I realized that people cannot see my "unregistered" forum topics now :-) Ack..

Thanks again for all the work!!

-Jason

paulomt1 01-11-2004 12:58 AM

Excellent, thank you!!!

idwf 01-11-2004 08:09 AM

Quote:

Originally Posted by paulomt1
Excellent, thank you!!!

*install*

The Keeper 01-11-2004 09:58 AM

What about unregistered Google Bots?

nuke 01-11-2004 10:08 AM

Big Thx Install

Gary King 01-11-2004 02:48 PM

Quote:

Originally Posted by The Keeper
What about unregistered Google Bots?

They can archive the built-in vB 3 archive :)

nighteyes 01-11-2004 03:29 PM

Short, sweet, and works superbly well. I share the sentiments of the other posters this should be the default way in vBulletin. I can see our registrations rocketing with this. Well done.

azmi 01-12-2004 11:21 AM

after installing this hack, i wondered alll users browsing through threads.
they all registered themselves new, but there was no need to accept the account by mail.
directly after register on board (nothing with mail), you can browse as a correctly registered user!

is there anything, you can make it with (id:3,1,....) for groups?

Feran 01-12-2004 01:27 PM

Quote:

Originally Posted by aliencode
Wow nice - woah this really SHOULD be the default hmm wonder what Vbulletin was thinking when they wrote the original.

'tis a bit strange, actually, but you're still kinda violating your own privacy by listing Last Post Titles again.. If your'e going to show *those*, why not enable Guest-viewing of threads?

I admit I didn't enjoy the 0 thing too though.. I suppose this feature is a little nifty o.O;;

Gary King 01-12-2004 11:02 PM

Quote:

Originally Posted by azmi
after installing this hack, i wondered alll users browsing through threads.
they all registered themselves new, but there was no need to accept the account by mail.
directly after register on board (nothing with mail), you can browse as a correctly registered user!

is there anything, you can make it with (id:3,1,....) for groups?

Change the added code to:

PHP Code:

if ($bbuserinfo['userid'] == or $bbuserinfo['usergroupid'] == X

    
print_no_permission(); 


Replace X with whatever usergroupid you want :)

azmi 01-13-2004 06:59 AM

thats exactly what i want

big Thx

-----------------------
hmmm - only for me?
i can not add any php-code or smilies!
there is always an "#" to go to the top ?!

dano 01-13-2004 03:47 PM

Quote:

Originally Posted by Faranth
could also be done via a template mod :)
in a slightly differnt way of course ;D

How?

Darnell 0216 01-14-2004 01:46 AM

Nice hack. I got tired of staring at the 0's... made the place seem so empty.

Rampag33 01-14-2004 02:01 PM

Great. Much needed.

dano 01-14-2004 03:16 PM

Quote:

Originally Posted by Gary W
They can archive the built-in vB 3 archive :)

Does the archive turn off when you turn off the viewing for guests? I am worried that the search engines will not be able to search if I use this.

Zachery 01-14-2004 03:19 PM

Quote:

Originally Posted by dano
Does the archive turn off when you turn off the viewing for guests? I am worried that the search engines will not be able to search if I use this.

no if the archive is enabled everyone with the correct permssions can see it

gmarik 01-14-2004 07:33 PM

and this does help a small board?

maurier 01-15-2004 05:20 AM

great hack ! Gary W
can you make this hack disallow members downloads attached files when member dont post x new threads or reply any threads ?

thank so much !

Zachery 01-15-2004 05:25 AM

Quote:

Originally Posted by maurier
great hack ! Gary W
can you make this hack disallow members downloads attached files when member dont post x new threads or reply any threads ?

thank so much !

Maurier please read this https://vborg.vbsupport.ru/showthrea...634#post462634

anabolicedge 01-21-2004 05:27 PM

my google bots are getting https://vborg.vbsupport.ru/ Viewing 'No Permission' Message on all threads. google bot was fine before this!?!?!

Gary King 01-22-2004 11:15 AM

Quote:

Originally Posted by anabolicedge
my google bots are getting http://www.anabolicedge.net/forum/im...permission.gif Viewing 'No Permission' Message on all threads. google bot was fine before this!?!?!

Because they are listed as guests, but they can still archive the built-in vB 3 archive, but not the actual threads.

Mephisteus 01-23-2004 06:41 PM

Quote:

Originally Posted by Gary W
Because they are listed as guests, but they can still archive the built-in vB 3 archive, but not the actual threads.

should go into the mini mods subforum btw :)

dano 01-23-2004 09:27 PM

This is working for me but I have an addittional question. Does anyone know where I go to edit the print_no_permission page? I want to make it MUCH more clear to guests that they need to register. In VB2 it was a templete but I cant seem to find it in VB3

Gary King 01-24-2004 12:53 PM

Quote:

Originally Posted by dano
This is working for me but I have an addittional question. Does anyone know where I go to edit the print_no_permission page? I want to make it MUCH more clear to guests that they need to register. In VB2 it was a templete but I cant seem to find it in VB3

This template: username_loggedout

Gary King 01-24-2004 12:54 PM

Quote:

Originally Posted by DarkSSJ3
should go into the mini mods subforum btw :)

I think I posted this before I knew there was a mini-mod forum anyways :)


All times are GMT. The time now is 07:57 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01443 seconds
  • Memory Usage 1,833KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (7)bbcode_php_printable
  • (14)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete