Eval a file, and it gives parse error because it uses a preg_match statement with \$

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



And well, this is kind of annoying aswell..

A variable isnt getting passed to the files it Evals..

Basically, its the new template engine im coding, its a class, its about 8x
faster than the old method of buffering.

In the class I evaluate the template, but variables from files included by
the evaluated files do not work, also variables from the main engine dont
pass to the file.

Globals are obviously off, and will stay off.

eval("?>" . $this -> The_Template_Sys . "<?");

Class.php has the class.
engine.php calls the class, and executes stuff in the class, gets the
configuration and all that, sets some variables like template etc..
file.php calls engine which calls the realfile.php and the class loads the
file,

Right now, its file_get_contents, then eval.

but, the the variables that are in file.php do not work in the realfile.php
if realfile.php calls another config file (seperate, or with the engine) the
variables DO NOT SET.

Any ideas?

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux