@@ -73,7 +73,8 @@ class BootstrapHtmlHelper extends HtmlHelper {
7373 *
7474 **/
7575 public function icon ($ icon , $ options = []) {
76- return $ this ->config ('useFontAwesome ' ) ? $ this ->faIcon ($ icon , $ options ) : $ this ->glIcon ($ icon , $ options );
76+ return $ this ->config ('useFontAwesome ' )?
77+ $ this ->faIcon ($ icon , $ options ) : $ this ->glIcon ($ icon , $ options );
7778 }
7879
7980 /**
@@ -188,8 +189,12 @@ public function alert ($text, $type = 'warning', $options = []) {
188189 $ options += [
189190 'type ' => 'warning '
190191 ];
191- $ button = '<button type="button" class="close" data-dismiss="alert" aria-hidden="true"> '
192- .'×</button> ' ;
192+ $ button = $ this ->tag ('button ' , '× ' , [
193+ 'type ' => 'button ' ,
194+ 'class ' => 'close ' ,
195+ 'data-dismiss ' => 'alert ' ,
196+ 'aria-hidden ' => true
197+ ]);
193198 $ type = $ options ['type ' ];
194199 unset($ options ['type ' ]) ;
195200 $ options = $ this ->addClass ($ options , 'alert ' ) ;
@@ -343,7 +348,8 @@ public function dropdown (array $menu = [], array $options = []) {
343348 $ url = array_shift ($ action ) ;
344349 $ action ['role ' ] = 'menuitem ' ;
345350 $ action ['tabindex ' ] = -1 ;
346- $ output .= '<li role="presentation"> ' .$ this ->link ($ name , $ url , $ action ).'</li> ' ;
351+ $ output .= '<li role="presentation"> '
352+ .$ this ->link ($ name , $ url , $ action ).'</li> ' ;
347353 }
348354 }
349355 else {
0 commit comments