| @@ -5,25 +5,13 @@ | ||
| 5 | 5 | * ********************************************************* */ |
| 6 | 6 | |
| 7 | 7 | function osc_theme_icon($params, $content = null) { |
| 8 | 8 | extract(shortcode_atts(array( |
| 9 | - 'type' => '', | |
| 10 | - 'color'=>'', | |
| 11 | - 'class' => '', | |
| 12 | - 'fontsize'=>'' | |
| 13 | - ), $params)); | |
| 14 | - if($color!=''){ | |
| 15 | - $color='color:'.$color.';'; | |
| 16 | - } | |
| 17 | - if($fontsize!=''){ | |
| 18 | - $fontsize=' font-size:'.$fontsize.'px;'; | |
| 19 | - } | |
| 20 | - $iconcount=explode(' ',$type); | |
| 21 | - array_filter($iconcount); | |
| 22 | - if(count($iconcount)==1){ | |
| 23 | - $type= 'glyphicon '.$type; | |
| 24 | - } | |
| 25 | - $out = '<i class=" ' . $type . ' ' . $class . '" style="'.$color.$fontsize.'"></i>'; | |
| 9 | + 'type' => '', | |
| 10 | + 'class' => '', | |
| 11 | + ), $params)); | |
| 12 | + $out = '<i class="glyphicon ' . $type . ' ' . $class . '"></i>'; | |
| 26 | 13 | return $out; |
| 27 | 14 | } |
| 28 | 15 | |
| 29 | -ebs_backward_compatibility_callback('icon', 'osc_theme_icon'); | |
| 16 | +add_shortcode('icon', 'osc_theme_icon'); | |
| 17 | + | |