Skip to content
Extraits de code Groupes Projets
Valider 6ed0125b rédigé par robocoder's avatar robocoder
Parcourir les fichiers

Synced up with PEAR svn repository revision 301028

 * add HTML_QuickForm2_Renderer_Smarty
 * comment out require_once
 * let autoloaders try loading class first - http://pear.php.net/bugs/bug.php?id=17568
 * HTML_QuickForm_Node - http://pear.php.net/bugs/17557



git-svn-id: http://dev.piwik.org/svn/trunk@2437 59fd770c-687e-43c8-a1e3-f5a4ff64c105
parent 657a4852
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
Affichage de
avec 38 ajouts et 36 suppressions
...@@ -46,12 +46,12 @@ ...@@ -46,12 +46,12 @@
/** /**
* Abstract base class for QuickForm2 containers * Abstract base class for QuickForm2 containers
*/ */
require_once 'HTML/QuickForm2/Container.php'; // require_once 'HTML/QuickForm2/Container.php';
/** /**
* Data source for HTML_QuickForm2 objects based on superglobal arrays * Data source for HTML_QuickForm2 objects based on superglobal arrays
*/ */
require_once 'HTML/QuickForm2/DataSource/SuperGlobal.php'; // require_once 'HTML/QuickForm2/DataSource/SuperGlobal.php';
/** /**
* Class representing a HTML form * Class representing a HTML form
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Base class for all HTML_QuickForm2 elements * Base class for all HTML_QuickForm2 elements
*/ */
require_once 'HTML/QuickForm2/Node.php'; // require_once 'HTML/QuickForm2/Node.php';
/** /**
* Abstract base class for simple QuickForm2 containers * Abstract base class for simple QuickForm2 containers
...@@ -433,7 +433,7 @@ abstract class HTML_QuickForm2_Container extends HTML_QuickForm2_Node ...@@ -433,7 +433,7 @@ abstract class HTML_QuickForm2_Container extends HTML_QuickForm2_Node
public function __toString() public function __toString()
{ {
require_once 'HTML/QuickForm2/Renderer.php'; // require_once 'HTML/QuickForm2/Renderer.php';
return $this->render(HTML_QuickForm2_Renderer::factory('default'))->__toString(); return $this->render(HTML_QuickForm2_Renderer::factory('default'))->__toString();
} }
...@@ -484,4 +484,4 @@ class HTML_QuickForm2_ContainerIterator extends RecursiveArrayIterator implement ...@@ -484,4 +484,4 @@ class HTML_QuickForm2_ContainerIterator extends RecursiveArrayIterator implement
} }
} }
?> ?>
\ No newline at end of file
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Base class for fieldsets * Base class for fieldsets
*/ */
require_once 'HTML/QuickForm2/Container.php'; // require_once 'HTML/QuickForm2/Container.php';
/** /**
* Concrete implementation of a container for fieldsets * Concrete implementation of a container for fieldsets
...@@ -89,4 +89,4 @@ class HTML_QuickForm2_Container_Fieldset extends HTML_QuickForm2_Container ...@@ -89,4 +89,4 @@ class HTML_QuickForm2_Container_Fieldset extends HTML_QuickForm2_Container
throw new HTML_QuickForm2_Exception('Not implemented'); throw new HTML_QuickForm2_Exception('Not implemented');
} }
} }
?> ?>
\ No newline at end of file
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Base class for all HTML_QuickForm2 containers * Base class for all HTML_QuickForm2 containers
*/ */
require_once 'HTML/QuickForm2/Container.php'; // require_once 'HTML/QuickForm2/Container.php';
/** /**
* Base class for QuickForm2 groups of elements * Base class for QuickForm2 groups of elements
...@@ -317,7 +317,7 @@ class HTML_QuickForm2_Container_Group extends HTML_QuickForm2_Container ...@@ -317,7 +317,7 @@ class HTML_QuickForm2_Container_Group extends HTML_QuickForm2_Container
public function __toString() public function __toString()
{ {
require_once 'HTML/QuickForm2/Renderer.php'; // require_once 'HTML/QuickForm2/Renderer.php';
return $this->render( return $this->render(
HTML_QuickForm2_Renderer::factory('default') HTML_QuickForm2_Renderer::factory('default')
...@@ -325,4 +325,4 @@ class HTML_QuickForm2_Container_Group extends HTML_QuickForm2_Container ...@@ -325,4 +325,4 @@ class HTML_QuickForm2_Container_Group extends HTML_QuickForm2_Container
)->__toString(); )->__toString();
} }
} }
?> ?>
\ No newline at end of file
...@@ -44,13 +44,13 @@ ...@@ -44,13 +44,13 @@
*/ */
/** The class representing a page of a multipage form */ /** The class representing a page of a multipage form */
require_once 'HTML/QuickForm2/Controller/Page.php'; // require_once 'HTML/QuickForm2/Controller/Page.php';
/** Object wrapping around session variable used to store controller data */ /** Object wrapping around session variable used to store controller data */
require_once 'HTML/QuickForm2/Controller/SessionContainer.php'; // require_once 'HTML/QuickForm2/Controller/SessionContainer.php';
/** Class presenting the values stored in session by Controller as submitted ones */ /** Class presenting the values stored in session by Controller as submitted ones */
require_once 'HTML/QuickForm2/DataSource/Session.php'; // require_once 'HTML/QuickForm2/DataSource/Session.php';
/** /**
* Class implementing the Page Controller pattern for multipage forms * Class implementing the Page Controller pattern for multipage forms
...@@ -295,7 +295,9 @@ class HTML_QuickForm2_Controller implements IteratorAggregate ...@@ -295,7 +295,9 @@ class HTML_QuickForm2_Controller implements IteratorAggregate
&& in_array($actionName, array('next', 'back', 'submit', 'display', 'jump')) && in_array($actionName, array('next', 'back', 'submit', 'display', 'jump'))
) { ) {
$className = 'HTML_QuickForm2_Controller_Action_' . ucfirst($actionName); $className = 'HTML_QuickForm2_Controller_Action_' . ucfirst($actionName);
HTML_QuickForm2_Loader::loadClass($className); if (!class_exists($className)) {
HTML_QuickForm2_Loader::loadClass($className);
}
$this->addHandler($actionName, new $className()); $this->addHandler($actionName, new $className());
} }
if (isset($this->handlers[$actionName])) { if (isset($this->handlers[$actionName])) {
...@@ -503,4 +505,4 @@ class HTML_QuickForm2_Controller implements IteratorAggregate ...@@ -503,4 +505,4 @@ class HTML_QuickForm2_Controller implements IteratorAggregate
return new ArrayIterator($this->pages); return new ArrayIterator($this->pages);
} }
} }
?> ?>
\ No newline at end of file
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/** Interface for Controller action handlers */ /** Interface for Controller action handlers */
require_once 'HTML/QuickForm2/Controller/Action.php'; // require_once 'HTML/QuickForm2/Controller/Action.php';
/** /**
* Action handler for a 'back' button of wizard-type multipage form * Action handler for a 'back' button of wizard-type multipage form
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/** Interface for Controller action handlers */ /** Interface for Controller action handlers */
require_once 'HTML/QuickForm2/Controller/Action.php'; // require_once 'HTML/QuickForm2/Controller/Action.php';
/** /**
* Action handler for going to a specific page of a multipage form * Action handler for going to a specific page of a multipage form
......
...@@ -44,10 +44,10 @@ ...@@ -44,10 +44,10 @@
*/ */
/** Interface for Controller action handlers */ /** Interface for Controller action handlers */
require_once 'HTML/QuickForm2/Controller/Action.php'; // require_once 'HTML/QuickForm2/Controller/Action.php';
/** Class presenting the values stored in session by Controller as submitted ones */ /** Class presenting the values stored in session by Controller as submitted ones */
require_once 'HTML/QuickForm2/DataSource/Session.php'; // require_once 'HTML/QuickForm2/DataSource/Session.php';
/** /**
* Action handler for outputting the form * Action handler for outputting the form
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/** Interface for Controller action handlers */ /** Interface for Controller action handlers */
require_once 'HTML/QuickForm2/Controller/Action.php'; // require_once 'HTML/QuickForm2/Controller/Action.php';
/** /**
* This handler performs an HTTP redirect to a specific page * This handler performs an HTTP redirect to a specific page
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/** Interface for Controller action handlers */ /** Interface for Controller action handlers */
require_once 'HTML/QuickForm2/Controller/Action.php'; // require_once 'HTML/QuickForm2/Controller/Action.php';
/** /**
* Action handler for a 'next' button of wizard-type multipage form * Action handler for a 'next' button of wizard-type multipage form
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/** Interface for Controller action handlers */ /** Interface for Controller action handlers */
require_once 'HTML/QuickForm2/Controller/Action.php'; // require_once 'HTML/QuickForm2/Controller/Action.php';
/** /**
* Action handler for a 'submit' button * Action handler for a 'submit' button
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/** Class for <input type="image" /> elements */ /** Class for <input type="image" /> elements */
require_once 'HTML/QuickForm2/Element/InputImage.php'; // require_once 'HTML/QuickForm2/Element/InputImage.php';
/** /**
* A hidden button used to submit the form when the user presses Enter * A hidden button used to submit the form when the user presses Enter
......
...@@ -180,7 +180,7 @@ abstract class HTML_QuickForm2_Controller_Page ...@@ -180,7 +180,7 @@ abstract class HTML_QuickForm2_Controller_Page
*/ */
public function setDefaultAction($actionName, $imageSrc = '') public function setDefaultAction($actionName, $imageSrc = '')
{ {
require_once 'HTML/QuickForm2/Controller/DefaultAction.php'; // require_once 'HTML/QuickForm2/Controller/DefaultAction.php';
if (0 == count($this->form)) { if (0 == count($this->form)) {
$image = $this->form->appendChild( $image = $this->form->appendChild(
...@@ -255,4 +255,4 @@ abstract class HTML_QuickForm2_Controller_Page ...@@ -255,4 +255,4 @@ abstract class HTML_QuickForm2_Controller_Page
return $container->getValidationStatus($id); return $container->getValidationStatus($id);
} }
} }
?> ?>
\ No newline at end of file
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Interface for data sources used by HTML_QuickForm2 objects * Interface for data sources used by HTML_QuickForm2 objects
*/ */
require_once 'HTML/QuickForm2/DataSource.php'; // require_once 'HTML/QuickForm2/DataSource.php';
/** /**
* Array-based data source for HTML_QuickForm2 objects * Array-based data source for HTML_QuickForm2 objects
......
...@@ -44,10 +44,10 @@ ...@@ -44,10 +44,10 @@
*/ */
/** Interface for data sources containing submitted values */ /** Interface for data sources containing submitted values */
require_once 'HTML/QuickForm2/DataSource/Submit.php'; // require_once 'HTML/QuickForm2/DataSource/Submit.php';
/** Array-based data source for HTML_QuickForm2 objects */ /** Array-based data source for HTML_QuickForm2 objects */
require_once 'HTML/QuickForm2/DataSource/Array.php'; // require_once 'HTML/QuickForm2/DataSource/Array.php';
/** /**
* Class presenting the values stored in session by Controller as submitted ones * Class presenting the values stored in session by Controller as submitted ones
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Interface for data sources used by HTML_QuickForm2 objects * Interface for data sources used by HTML_QuickForm2 objects
*/ */
require_once 'HTML/QuickForm2/DataSource.php'; // require_once 'HTML/QuickForm2/DataSource.php';
/** /**
* Interface for data sources containing submitted values * Interface for data sources containing submitted values
......
...@@ -46,12 +46,12 @@ ...@@ -46,12 +46,12 @@
/** /**
* Interface for data sources containing submitted values * Interface for data sources containing submitted values
*/ */
require_once 'HTML/QuickForm2/DataSource/Submit.php'; // require_once 'HTML/QuickForm2/DataSource/Submit.php';
/** /**
* Array-based data source for HTML_QuickForm2 objects * Array-based data source for HTML_QuickForm2 objects
*/ */
require_once 'HTML/QuickForm2/DataSource/Array.php'; // require_once 'HTML/QuickForm2/DataSource/Array.php';
/** /**
* Data source for HTML_QuickForm2 objects based on superglobal arrays * Data source for HTML_QuickForm2 objects based on superglobal arrays
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Base class for all HTML_QuickForm2 elements * Base class for all HTML_QuickForm2 elements
*/ */
require_once 'HTML/QuickForm2/Node.php'; // require_once 'HTML/QuickForm2/Node.php';
/** /**
* Abstract base class for simple QuickForm2 elements (not Containers) * Abstract base class for simple QuickForm2 elements (not Containers)
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
/** /**
* Base class for simple HTML_QuickForm2 elements * Base class for simple HTML_QuickForm2 elements
*/ */
require_once 'HTML/QuickForm2/Element.php'; // require_once 'HTML/QuickForm2/Element.php';
/** /**
* Class for <button> elements * Class for <button> elements
......
...@@ -46,11 +46,11 @@ ...@@ -46,11 +46,11 @@
/** /**
* Base class for HTML_QuickForm2 group of elements * Base class for HTML_QuickForm2 group of elements
*/ */
require_once 'HTML/QuickForm2/Container/Group.php'; // require_once 'HTML/QuickForm2/Container/Group.php';
/** /**
* Base class for HTML_QuickForm2 select element * Base class for HTML_QuickForm2 select element
*/ */
require_once 'HTML/QuickForm2/Element/Select.php'; // require_once 'HTML/QuickForm2/Element/Select.php';
/** /**
* Class for a group of elements used to input dates (and times). * Class for a group of elements used to input dates (and times).
...@@ -500,4 +500,4 @@ class HTML_QuickForm2_Element_Date extends HTML_QuickForm2_Container_Group ...@@ -500,4 +500,4 @@ class HTML_QuickForm2_Element_Date extends HTML_QuickForm2_Container_Group
) )
); );
} }
?> ?>
\ No newline at end of file
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter