cvs: php4 /pear/HTML IT.php

From: Date: Mon, 21 Jan 2002 17:20:14 +0000
Subject: cvs: php4 /pear/HTML IT.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-2045@lists.php.net to get a copy of this message
mj Mon Jan 21 12:20:14 2002 EDT Modified files: /php4/pear/HTML IT.php Log: * Add possibility to load external files in template. (Patch by Christian Dickmann <chrisdicki@gmx.de>.) Index: php4/pear/HTML/IT.php diff -u php4/pear/HTML/IT.php:1.11 php4/pear/HTML/IT.php:1.12 --- php4/pear/HTML/IT.php:1.11 Fri Dec 14 11:24:59 2001 +++ php4/pear/HTML/IT.php Mon Jan 21 12:20:14 2002 @@ -16,7 +16,7 @@ // | Authors: Ulf Wendel <ulf.wendel@phpdoc.de> | // +----------------------------------------------------------------------+ // -// $Id: IT.php,v 1.11 2001/12/14 16:24:59 mj Exp $ +// $Id: IT.php,v 1.12 2002/01/21 17:20:14 mj Exp $ // require_once('HTML/IT_Error.php'); @@ -112,7 +112,7 @@ * </code> * * @author Ulf Wendel <uw@netuse.de> -* @version $Id: IT.php,v 1.11 2001/12/14 16:24:59 mj Exp $ +* @version $Id: IT.php,v 1.12 2002/01/21 17:20:14 mj Exp $ * @access public * @package IX[X] */ @@ -785,7 +785,7 @@ $content = fread($fh, filesize($filename)); fclose($fh); - return $content; + return preg_replace("#<!-- INCLUDE (.*) -->#ime", "\$this->getFile('\\1')", $content); } // end func getFile } // end class IntegratedTemplate

« previous php.pear.cvs (#2045) next »