Bootstrap Templates Bundle

Monday, December 29, 2014

Progress bar: Making short code in Bootstrap Wordpress

Add this code to your functions.php file ---------------------------------------------------

function progress($atts, $content = null) {
 extract( shortcode_atts( array(        
          'percentage' => ''
), $atts ) );

return '<div class="progress">
  <div class="progress-bar" role="progressbar" aria-valuenow="'.$percentage.'" aria-valuemin="0" aria-valuemax="100" style="width: '.$percentage.'%;">
    ' . $percentage . '%

add_shortcode('progressbar', 'progress');

How To Use:

 [progressbar percentage="60"]60%[/progressbar]
 [progressbar percentage="70"]70%[/progressbar]

Murphy - Home Maintenance & Repair Service HTML Template

Murphy is a handyman repair service Bootstrap HTML Template. It is ideal for either all-rounders or professional teams to introduce the...