@@ 441-449 (lines=9) @@ | ||
438 | /** |
|
439 | * @return $this |
|
440 | */ |
|
441 | public function addClass() |
|
442 | { |
|
443 | $classes = func_get_args(); |
|
444 | if (is_array($classes)) { |
|
445 | $oldClasses = explode(' ', $this->getAttrib('class')); |
|
446 | $classes = array_merge($classes, $oldClasses); |
|
447 | $this->setAttrib('class', implode(' ', $classes)); |
|
448 | } |
|
449 | ||
450 | return $this; |
|
451 | } |
|
452 |
@@ 25-33 (lines=9) @@ | ||
22 | $this->addClass('btn', 'btn-primary'); |
|
23 | } |
|
24 | ||
25 | public function addClass() |
|
26 | { |
|
27 | $classes = func_get_args(); |
|
28 | if (is_array($classes)) { |
|
29 | $oldClasses = explode(' ', $this->getAttrib('class')); |
|
30 | $classes = array_merge($classes, $oldClasses); |
|
31 | $this->setAttrib('class', implode(' ', $classes)); |
|
32 | } |
|
33 | ||
34 | return $this; |
|
35 | } |
|
36 |
@@ 241-249 (lines=9) @@ | ||
238 | /** |
|
239 | * @return $this |
|
240 | */ |
|
241 | public function addClass() |
|
242 | { |
|
243 | $classes = func_get_args(); |
|
244 | if (is_array($classes)) { |
|
245 | $oldClasses = explode(' ', $this->getAttrib('class')); |
|
246 | $classes = array_merge($classes, $oldClasses); |
|
247 | $this->setAttrib('class', implode(' ', $classes)); |
|
248 | } |
|
249 | ||
250 | return $this; |
|
251 | } |
|
252 |