Skip to content

Instantly share code, notes, and snippets.

@chrillep
Last active August 29, 2015 14:08
Show Gist options
  • Save chrillep/ab5fc95ec99037716a8d to your computer and use it in GitHub Desktop.
Save chrillep/ab5fc95ec99037716a8d to your computer and use it in GitHub Desktop.
Twitter bootstrap WP-e-Commerce Pagination Filter
function bootstrap_custom_wpsc_pagination($output){
$output = '<nav><ul class="pagination">' . $output;
$output = str_replace(
array( '<a', '</a>',"<span class='current'>", '</span>', __('Pages: ','wpsc')),
array( '<li><a', '</a></li>','<li class="current active"><a href="#">', '<span class="sr-only">(current)</span></a></li>', '<li class="disabled"><span>' . __('Pages: ','wpsc') . '</span></li>'),
$output);
$output = $output . '</ul></nav>';
return $output;
}
add_filter( 'wpsc_pagination', 'bootstrap_custom_wpsc_pagination' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment