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 hide a part of the post ? (https://vborg.vbsupport.ru/showthread.php?t=196724)

ishare 11-19-2008 08:03 PM

How to hide a part of the post ?
 
Hi,
I would like to learn if it is possible to hide a part of the text in a post/thread ?

I tried to do something like below with "spoiler" ( [spoiler]text[/spoiler] ) bbcode, but didnt work. :)

Code:

<if condition="is_member_of($bbuserinfo, 4,5,6)"><center><TABLE WIDTH="750" BORDER="0" align="center" CELLPADDING="5" CELLSPACING="10" BGCOLOR="#E0E0E0">
  <TR>
  <TD BGCOLOR="#edece9"><div align="center"><div id="spoiler">
    <div>
        <div align="center">
          <input type="button" id="pagenav_ibtn" value="Show Text!" style="border:1px solid #353533; width:720px;font-size:12px;margin:0px;padding:2px; background-color:#FFFFFF" onclick="if (this.parentNode.parentNode.getElementsByTagName('div')['show'].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')['show'].style.display = ''; this.parentNode.parentNode.getElementsByTagName('div')['hide'].style.display = 'none'; this.innerText = ''; this.value = 'Hide Text!'; } else { this.parentNode.parentNode.getElementsByTagName('div')['show'].style.display = 'none'; this.parentNode.parentNode.getElementsByTagName('div')['hide'].style.display = ''; this.innerText = ''; this.value = 'Show Text!'; }" />
      </div>
        <div id="show" style="display: none; background-color:#f7f6f3;">
            {param}
        </div>
        <div id="hide">
        </div>
  </div>
</div></div></TD>
</TR></TABLE></center></if>

The reason i would like to do something like this is, i want everybody to see the post but authorized (active members and admins etc...) will see all post including the hidden text and other members (standart members, guests, coppa etc...) will see the rest of the thread but not hidden text.

Another point with this customization is, authorized members should be able to use this command/code (whatever we call it) too. Because they also post threads which other members should not see some part of it.

I hope its possible to do something like this.

Thanks in advance
Regards


All times are GMT. The time now is 03: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.01293 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
  • (1)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