Gambler ZG wrote:

Let’s say I have function named "render", which looks like this:

<?php
function render($template, $vars){
    extract($vars);
    include("templates/".$template.'.php');
}
?>

I also have template "some_tmplt.php", which I need to render 100 times. Will PHP read, parse and compile this file 100 times, or will it "remember" file's content?

not sure if i understnad your question. If you want to cache the compiled php script look at Turck MMCache. If you want to avoid the same file being included twice in your script look at include_once() or require_once()



--
Raditha Dissanayake.
------------------------------------------------------------------------
http://www.radinks.com/sftp/         | http://www.raditha.com/megaupload
Lean and mean Secure FTP applet with | Mega Upload - PHP file uploader
Graphical User Inteface. Just 128 KB | with progress bar.

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



Reply via email to