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
Links for Registered Users Only Details »»
Links for Registered Users Only
Version: 1.00, by Deaths Deaths is offline
Developer Last Online: Mar 2009 Show Printable Version Email this Page

Version: 3.0.7 Rating:
Released: 05-13-2005 Last Update: Never Installs: 25
 
No support by the author.

Very simple hack, as requested here.

What does it do?
All links can only be viewed by registered members.

Time to install: 5 minutes, if not less
Files to edit: 1

Open up includes/functions_bbcodeparse.php, and find:
PHP Code:
return "<a href=\"$rightlink\" target=\"_blank\">$text</a>"
Replace with:
PHP Code:
global $bbuserinfo;
if (
$bbuserinfo[userid] != 0)
{
return 
"<a href=\"$rightlink\" target=\"_blank\">$text</a>";
}
else
{
return 
"Guests cannot view links. You must <a href='register.php'>register</a> to see links.";

Thats it .

NOTE:
If you are using Floris' standard URL hyperlink opening in same window, the first step is:

Find
PHP Code:
return "<a href=\"$rightlink\">$text</a>"
If you are using Postcache, you might need to rebuild it.

Please click install if used!

Supporters / CoAuthors

Show Your Support

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

Comments
  #32  
Old 09-17-2005, 11:21 AM
Yorixz Yorixz is offline
 
Join Date: Jun 2005
Location: Netherlands
Posts: 284
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by sajjid
ok for this to work in vb 3.5 rc 3 do the following in
forums/includes/class_bbcode.php
find
Code:
return "<a href=\"$rightlink\" target=\"_blank\">$text</a>";
and replace it with
Code:
if ($vbulletin->userinfo['userid'])   
{  
return "<a href=\"$rightlink\" target=\"_blank\">$text</a>"; 
}  
else  
{  
return "Guests cannot view links. You must <a href='register.php'>register</a> to see links."; 
}
Do you also happen to know what the condition would be to only allow people in a usergroup higher than, say 6?
Reply With Quote
  #33  
Old 09-26-2005, 01:42 AM
smokering smokering is offline
 
Join Date: Mar 2004
Posts: 37
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice addon thank you much
Reply With Quote
  #34  
Old 10-04-2005, 09:27 PM
Andyrew Andyrew is offline
 
Join Date: Aug 2005
Location: UK
Posts: 250
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What code for 3.5 gold tried the above but even i the admin cannot view links. ??

Thanks
Reply With Quote
  #35  
Old 05-09-2006, 09:14 PM
AyeCapn's Avatar
AyeCapn AyeCapn is offline
 
Join Date: May 2006
Location: Edmonton, AB
Posts: 146
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default



can this be adapted in someway to prevent non-registered users from viewing signatures?
Reply With Quote
  #36  
Old 03-06-2007, 04:24 AM
dragonlove dragonlove is offline
 
Join Date: Oct 2004
Posts: 41
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

vB Version: 3.0.7

This hack is too old, where is the new one that works with 3.6.5 ?
Reply With Quote
  #37  
Old 03-11-2007, 05:41 AM
tyler_d tyler_d is offline
 
Join Date: Aug 2006
Location: Macon, GA
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by dragonlove View Post
vB Version: 3.0.7

This hack is too old, where is the new one that works with 3.6.5 ?
yeah, would love to know this too
Reply With Quote
  #38  
Old 05-30-2007, 11:18 PM
katie hunter's Avatar
katie hunter katie hunter is offline
 
Join Date: May 2007
Posts: 533
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I tried it but it didn't work i use vBulletin 3.6.7 PL1)
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:45 AM.


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.04434 seconds
  • Memory Usage 2,278KB
  • Queries Executed 23 (?)
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
  • (2)bbcode_code
  • (3)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
  • (8)post_thanks_box
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (8)post_thanks_postbit_info
  • (7)postbit
  • (8)postbit_onlinestatus
  • (8)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