Version: 1.00, by filburt1
Developer Last Online: May 2007
Version: 2.3.x
Rating:
Released: 05-10-2003
Last Update: Never
Installs: 16
No support by the author.
This hack lets you embed PHP code in templates. Simply add your code between a <? (not a <?php) and ?> tag and it will be eval'ed. All variables will be referenced in the global scope.
If you're using my Usergroup Tags in Templates hack then you're going to have an extraordinarily difficult time installing this hack. However the clever hacker can tell what has changed in this version.
You can somewhat use this to do conditionals in templates. Theoretically, this will work:
Just make sure that the variable to the left of the = and the variable right after the ?> match. Note that the entire <? and ?> tag itself will be stripped from the final template.
This hack also enhances the comments delimiting templates (if that option is turned on) to include the character count and PHP block count of the specified template.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
The problem with file inclusion is that this is completely contrary to the way in which vBulletin handles it's output buffering.
It doesn't generate line after line, it generates the entire page, and then sends that to the browser once it's compiled it.
For includes to work properly, anything (echos, output, etc.) would have to be stored as variables within the include, which are then echoed by the template itself.
Hello, sorry if this has been answered, I have read through and can't find anyhting relating to my problem.
I have installed the hack, I then dropped '<? ?>' (without the quotes) into the header of one of our templates. When I view the page it's not parsing the php, I can see the php tags in the source.
I then tried dropping an include in the same place but I then just get a blank page. I read that there are issues with using includes in the templates and I can live without using them although it would be very useful if I could.
Can you shead any light, let me know if you need any more details.
I am so glad that I found this hack, but the problem is that I'm having trouble installing it. I did exactly what is written in the file, the simple replacement of the code but this is what I get on the top of myVBindex.php.
Warning: Failed opening 'randomride.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/importhookup/public_html/forums/admin/functions.php(1095) : eval()'d code on line 1
Parse error: parse error, unexpected T_INCLUDE in /home/importhookup/public_html/forums/admin/functions.php(1095) : eval()'d code on line 1
Parse error: parse error, unexpected T_INCLUDE in /home/importhookup/public_html/forums/admin/functions.php(1095) : eval()'d code on line 1