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 insert a conditional inside a plugin (https://vborg.vbsupport.ru/showthread.php?t=169469)

valdet 02-02-2008 09:20 PM

How to insert a conditional inside a plugin
 
Hi there,

I woudl like to know if it is possible to insert some type of conditional in a plugin, so I restrict a particular thing only to one thread
Like this
Quote:

<if condition="$thread[threadid] == xx">
Use my trick
<else />
dont use it
</if>
maybe this needs a PHP conditional in teh shape of
Quote:

if (!$vbulletin->thread['threadid'] AND $vbulletin->thread['xx']) {
plugin code
;
}

Any quick help is appreciated.

Lynne 02-02-2008 09:37 PM

plugins need php. The format of the conditional ($vb-> thread vs $thread vs $threadinfo vs ??) may have to be played with depending on which plugin is being used.

valdet 02-02-2008 09:39 PM

I am using the [you] hack found here.
https://vborg.vbsupport.ru/showthread.php?p=1434344

while people are having fun at the specific thread at each other, they have started to use it in other threads too, therefore my point.

Does anyone got an advice

Boofo 02-02-2008 10:09 PM

Have you tried asking in that thread? ;)

Maybe explain what you are trying to do and we can figure it out there.

valdet 02-02-2008 10:51 PM

Quote:

Originally Posted by Boofo (Post 1434899)
Have you tried asking in that thread? ;)

Maybe explain what you are trying to do and we can figure it out there.

OK i posted the question there as well. I hope for some helpful advices.


All times are GMT. The time now is 09:01 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.01643 seconds
  • Memory Usage 1,716KB
  • 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)post_thanks_navbar_search
  • (1)printthread
  • (5)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