From e1b145a7068b886764efc4b0dfb9de4fa0526bca Mon Sep 17 00:00:00 2001 From: Antonio Ramirez Date: Tue, 28 May 2013 17:12:27 +0200 Subject: [PATCH] Enhance Dropdown to use items as strings. Remove string=divider rule --- framework/yii/bootstrap/Dropdown.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/framework/yii/bootstrap/Dropdown.php b/framework/yii/bootstrap/Dropdown.php index fa966d3..7a8cd51 100644 --- a/framework/yii/bootstrap/Dropdown.php +++ b/framework/yii/bootstrap/Dropdown.php @@ -40,11 +40,7 @@ class Dropdown extends Widget * 'items'=> array(...) * ) * ``` - * If you wish to display a `divider`, use any string. The widget will render a bootstrap dropdown divider: - * - * ```html - *
  • - * ``` + * Additionally, you can also configure a dropdown item as string. */ public $items = array(); @@ -80,7 +76,7 @@ class Dropdown extends Widget $contents = array(); foreach ($this->items as $item) { if (is_string($item)) { - $contents[] = Html::tag('li', '', array('class' => 'divider')); + $contents[] = $item; continue; } if (!isset($item['label'])) {