vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How To Allow Viewing of Thread Links But Not Posts - Only the activated (https://vborg.vbsupport.ru/showthread.php?t=74283)

bi11i 01-12-2005 10:22 PM

How To Allow Viewing of Thread Links But Not Posts - Only the activated
 
I was looking at using this code in my SHOWTHREAD template in order to allow unregistered users to only view the thread titles, and not the contained posts. This actually works great, but how would i change the code to allow this type of behavior for those who are registered and have completed their activation emails?
Code:

<!-- end content table -->
$spacer_close
<!-- / end content table -->

<if condition="$bbuserinfo['usergroupid'] != 1">

<if condition="$show['threadedmode'] OR $show['hybridmode']">
<!-- thread posts list -->
$threadlist
<!-- /thread posts list -->
</if>

<div id="posts">$postbits</div>

<else />

$spacer_open

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
        <td class="alt1">
        <div>Message that is displayed if user does not have permission to view posts.</div>
        </td>
</tr>
</table>

$spacer_close

</if>

<!-- start content table -->
$spacer_open
<!-- / start content table -->

same thing with PRINTTHREAD
Code:

(<span class="smallfont"><em>$vboptions[bburl]/showthread.php?t=$threadid</em></span>)
</div>

<br />

<if condition="$bbuserinfo['usergroupid'] != 1">

$postbits

<else />

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
        <td class="alt1">
        <div>Message that is displayed if user does not have permission to view posts.</div>
        </td>
</tr>
</table>

</if>

<br />

<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr valign="top">

here's the original post if this is too confusing: http://www.vbulletin.com/forum/showthread.php?t=110119


All times are GMT. The time now is 02:28 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.00945 seconds
  • Memory Usage 1,711KB
  • 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
  • (2)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (1)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete