![]() |
Trying to exclude a template using This Script but I keep getting errors
Ive read the posts and tried several ways but all keep giving me errors. Im using 4.2 on a php5 server. Any help would be great. Thanks.
All Im trying to do is exclude a template from one specific page using the "This Script" from that page. Code:
<if condition="THIS_SCRIPT != 'model_paint_database'"> Code:
The following error occurred when attempting to evaluate this template: Code:
Warning: Invalid argument supplied for foreach() in ..../includes/functions.php on line 3822 Actually, I just noticed something and I need to exclude it from 2 pages. It runs a JS that conflicts with those 2 pages. Thanks again. |
It looks like you're using vB 3.x template logic. :)
|
I followed directions for VB4 but you may be right. :rolleyes:
The plugin for the template is Code:
$templater = vB_Template::create('quickcalc'); Code:
{vb:raw quickcalc} So, any ideas on how to exclude this template from just 2 pages? |
What I mean is you want to use the following format within the template:
Code:
<vb:if condition="THIS_SCRIPT != 'model_paint_database'"> |
Good lord, how did I not see that? Works perfectly on the one page.
Any clue how to exclude on two pages? You know This Script and This Script. I cant find how to do this. And thanks for the help.... --------------- Added [DATE]1550986504[/DATE] at [TIME]1550986504[/TIME] --------------- Nevermind I just hardcoded the 2nd page to exclude that template. Its not ideal but it works. |
If you want to exclude multiple scripts, I would use for the condition:
Code:
!in_array(THIS_SCRIPT, array(script1, script2, ...)) |
All times are GMT. The time now is 06:23 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|