The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Plugin using global_complete hook, cant exclude from a forum using if conditional
This is replacement code from kh99, using global_complete hook, its works good
Code:
$find = 'Post New Thread'; $replace = 'Create a Listing'; $output = str_replace($find, $replace, $output); but now i want to exclude a forum already tried wrap it using below if conditional, but its not works Code:
if ($foruminfo['forumid'] != 123) { } Code:
if ($thread['forumid'] != 123) { } Code:
if ($post['forumid'] != 123) { } please help guys |
#2
|
||||
|
||||
Try the hook location "forum_display_start" and the plugin PHP code:
PHP Code:
|
Благодарность от: | ||
basketmen |
#3
|
||||
|
||||
its not only for forumdisplay, but for showthread too
it is better using forum_display_start hook or global_complete? |
#4
|
||||
|
||||
You have a "Post New Thread" button on your "showthread" pages?
|
#5
|
||||
|
||||
its just example text, i use for some text
|
#6
|
||||
|
||||
Ah okay, your initial post led me to believe you were trying to change the text that displays in the "Post New Thread" button.
|
#7
|
||||
|
||||
Quote:
so what is the right if conditional to exclude a forum with global_complete hook? |
#8
|
||||
|
||||
The forumid data does not appear to be available at that hook.
|
#10
|
||||
|
||||
thank you for reply, tried this
Code:
if ($GLOBAL['forumid'] != 123) { } any other code? hmm if its true, the only way is using forum_display_start hook and one more plugin for shothread_start |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|