Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function wpp_get_mostpopular($args = NULL, $return = false) {
- if ( is_null( $args ) ) {
- echo do_shortcode('[wpp]');
- } else {
- if( is_array( $args ) ){
- $atts = '';
- foreach( $args as $key => $arg ){
- $atts .= $key . '="' . $arg . '"';
- }
- } else {
- $atts = trim( str_replace( "&", " ", $args ) );
- }
- $out = do_shortcode( '[wpp '.$atts.']' );
- if( $return )
- return $out;
- echo $out;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement