cvs: pear /Template/Template Multipath.php

From: Date: Mon, 14 Jun 2004 08:44:46 +0000
Subject: cvs: pear /Template/Template Multipath.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-20639@lists.php.net to get a copy of this message
alan_k Mon Jun 14 04:44:46 2004 EDT Modified files: /pear/Template/Template Multipath.php Log: fix some typos http://cvs.php.net/diff.php/pear/Template/Template/Multipath.php?r1=1.2&r2=1.3&ty=u Index: pear/Template/Template/Multipath.php diff -u pear/Template/Template/Multipath.php:1.2 pear/Template/Template/Multipath.php:1.3 --- pear/Template/Template/Multipath.php:1.2 Mon Jun 14 04:37:17 2004 +++ pear/Template/Template/Multipath.php Mon Jun 14 04:44:46 2004 @@ -16,7 +16,7 @@ // | Authors: alan@akkbhome.com | // +----------------------------------------------------------------------+ // -// $Id: Multipath.php,v 1.2 2004/06/14 08:37:17 alan_k Exp $ +// $Id: Multipath.php,v 1.3 2004/06/14 08:44:46 alan_k Exp $ // // Multipath Provider - checks mulitple paths for the source of a template // @@ -26,7 +26,6 @@ /** * Default options related to this provider. - * Please document these...!!! * * @var array * @access public @@ -49,22 +48,11 @@ /** * initialize the Provider. * - * when the provider is created by the template, this method is called, with a - * reference to the template. - * - * Why not use PHP Constructors? - * unfortunatly this would make using a Provider as a Factory base class almost - * impossible (if not a little messy. - * - * Why not use a static Construct method? - * a) this may limit the same pattern in any subclasses. - * b) it gives you the posiblility to extend a base class, that does the same as this. - * - * * @param object Template The instantated template. * - * @return none (it may return a PEAR::Error) + * @return boolean (it may return a PEAR::Error) * @access public + * @see Template_Provider */ function initProvider(&$template) @@ -126,7 +114,7 @@ $newfile = $parts[1].'.'.$options['locale'] .$parts[2]; $dirs = array_unique($options['template_dir']); - if ($this->options['multisource.order'] == 'reverse') { + if ($options['multisource.order'] == 'reverse') { $dirs = array_reverse($dirs); } @@ -156,9 +144,9 @@ } // look in all the posible locations for the template directory.. - if ($this->currentTemplate === false) { + if ($files['currentTemplate'] === false) { $dirs = array_unique($options['templateDir']); - if ($this->options['multisource.order'] == 'reverse') { + if ($options['multisource.order'] == 'reverse') { $dirs = array_reverse($dirs); } foreach ($dirs as $tmplDir) {

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