initial commit
This commit is contained in:
commit
e869a1cab4
107 changed files with 9029 additions and 0 deletions
29
app/library/ViewHelper/Icon.php
Normal file
29
app/library/ViewHelper/Icon.php
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
<?php
|
||||
|
||||
namespace ViewHelper;
|
||||
|
||||
/**
|
||||
* Class Icon
|
||||
*
|
||||
* @package ViewHelper
|
||||
*/
|
||||
class Icon extends AbstractHelper
|
||||
{
|
||||
public function icon($name, $args = array())
|
||||
{
|
||||
$classes = array(
|
||||
'icon',
|
||||
'ion-' . $name
|
||||
);
|
||||
|
||||
if (is_array($args)) {
|
||||
|
||||
foreach($args as $arg) {
|
||||
$classes[] .= 'ion-' . $arg;
|
||||
}
|
||||
}
|
||||
|
||||
$classes = implode(' ', $classes);
|
||||
return '<i class="' . $classes . '"></i>';
|
||||
}
|
||||
}
|
||||
Reference in a new issue