Adding the possibility to use PHP code in main.tpl
would be really useful.
My site is using includes to set common headers, menus
and banners. Since main.tpl is the template that gives
the general structure of the page I need a way to at
least pull in some includes.
The way I solved the problem is by adding another flag
to the $config array which tells if there is PHP code
in main.tpl. If there is, then after parsing the
template it won't be just printed out, but first it
will be run through the 'eval' function.
See the attached files.
Log in to post a comment.