vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Advanced Templates: Dynamic Templates Changing according to different conditions (https://vborg.vbsupport.ru/showthread.php?t=43325)

Logician 01-24-2003 03:25 PM

Quote:

Originally posted by arracing
well in stead of userid how about usergroupid to block whole groups from seeing it.

You asked to stop unregistered usergroup's access and the code I gave does exactly this.. give it a try..

Logik 01-26-2003 01:44 AM

This is a wonderful hack. Thanks Logician ;)

Logik 01-27-2003 09:33 PM

This is a outstanding hack. It basically lets you use PHP in your templates. I believe everyone should install this. Would make hacking ALOT easier.

lowtaxbaby 01-28-2003 07:20 AM

While the example in the text file worked flawlessly (the code that goes in forumhome), whenever I attempt to put the code inside postbit, it simply prints out the code itself and completely ignores it. For example, if I put:

[[($bbuserinfo[usergroupid]==6)]]
Hello
[[/($bbuserinfo[usergroupid]==6)]]

It doesn't print out "Hello," but it prints out that entire code. Is there a switch or something somewhere that I have to turn off or on? I'm not good with vB, so any help would be most appreciated.

Thanks!

Logician 01-28-2003 10:31 AM

Quote:

Originally posted by lowtaxbaby
While the example in the text file worked flawlessly (the code that goes in forumhome), whenever I attempt to put the code inside postbit, it simply prints out the code itself and completely ignores it. For example, if I put:

[[($bbuserinfo[usergroupid]==6)]]
Hello
[[/($bbuserinfo[usergroupid]==6)]]

It doesn't print out "Hello," but it prints out that entire code. Is there a switch or something somewhere that I have to turn off or on? I'm not good with vB, so any help would be most appreciated.

Thanks!

It's supposed to work in all templates including postbit. Actually I have tested the conditional you referred above in my postbit now and it works ok here. I'm not sure if it is interfereing with another hack in your board or not? I can try to understand your problem if I have access to your admin cp but other than that I'm clueless.

Boofo 01-28-2003 03:23 PM

Quote:

Originally posted by lowtaxbaby
While the example in the text file worked flawlessly (the code that goes in forumhome), whenever I attempt to put the code inside postbit, it simply prints out the code itself and completely ignores it. For example, if I put:

[[($bbuserinfo[usergroupid]==6)]]
Hello
[[/($bbuserinfo[usergroupid]==6)]]

It doesn't print out "Hello," but it prints out that entire code. Is there a switch or something somewhere that I have to turn off or on? I'm not good with vB, so any help would be most appreciated.

Thanks!

Where exactly are you trying to insert the code in the postbit?

lowtaxbaby 01-28-2003 11:09 PM

We just downgraded back to version 2.2.6, and it works fine now. So sorry for posting that prematurely and thanks for the help!

Boofo 01-28-2003 11:12 PM

What version were you running where you had problems? I am running 2.2.9 and it works fine.

Logik 01-28-2003 11:13 PM

It should work for all versions. Works for my 2.2.9.. :)

Boofo 01-28-2003 11:19 PM

I don't know how I ever got along without this hack. I think I hack my templates more than I do my php files anymore. :)


All times are GMT. The time now is 07:12 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.02131 seconds
  • Memory Usage 1,736KB
  • 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
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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