| @@ 146-155 (lines=10) @@ | ||
| 143 | public function parse($arrAttributes=null) |
|
| 144 | { |
|
| 145 | $strClass = 'select'; |
|
| 146 | if ($this->multiple) |
|
| 147 | { |
|
| 148 | $this->strName .= '[]'; |
|
| 149 | $strClass = 'multiselect'; |
|
| 150 | } |
|
| 151 | // Make sure there are no multiple options in single mode |
|
| 152 | elseif (is_array($this->varValue)) |
|
| 153 | { |
|
| 154 | $this->varValue = $this->varValue[0]; |
|
| 155 | } |
|
| 156 | // Chosen |
|
| 157 | if ($this->chosen) |
|
| 158 | { |
|
| @@ 210-218 (lines=9) @@ | ||
| 207 | { |
|
| 208 | $strOptions = ''; |
|
| 209 | ||
| 210 | if ($this->multiple) |
|
| 211 | { |
|
| 212 | $this->strName .= '[]'; |
|
| 213 | } |
|
| 214 | // Make sure there are no multiple options in single mode |
|
| 215 | elseif (is_array($this->varValue)) |
|
| 216 | { |
|
| 217 | $this->varValue = $this->varValue[0]; |
|
| 218 | } |
|
| 219 | // Add empty option if there are none |
|
| 220 | if (empty($this->arrOptions) || !is_array($this->arrOptions)) |
|
| 221 | { |
|