1: <?php
2:
3: /**
4: * This file contains the cHTMLList class.
5: *
6: * @package Core
7: * @subpackage GUI_HTML
8: * @version SVN Revision $Rev:$
9: *
10: * @author Simon Sprankel
11: * @copyright four for business AG <www.4fb.de>
12: * @license http://www.contenido.org/license/LIZENZ.txt
13: * @link http://www.4fb.de
14: * @link http://www.contenido.org
15: */
16:
17: defined('CON_FRAMEWORK') || die('Illegal call: Missing framework initialization - request aborted.');
18:
19: /**
20: * cHTMLList class represents a list.
21: *
22: * @package Core
23: * @subpackage GUI_HTML
24: */
25: class cHTMLList extends cHTMLContentElement {
26:
27: /**
28: * Creates an HTML list element.
29: *
30: * @param string $type [optional]
31: * type of the list - ul or ol
32: * @param string $id [optional]
33: * the ID of the list element
34: * @param string $class [optional]
35: * the class of the list element
36: * @param array|string|object $elements [optional]
37: * the elements of this list
38: */
39: public function __construct($type = 'ul', $id = '', $class = '', $elements = array()) {
40: parent::__construct($elements, $class, $id);
41: if ($type !== 'ul' && $type !== 'ol') {
42: $type = 'ul';
43: }
44: $this->_tag = $type;
45: }
46:
47: }
48: