Skip to content

Commit

Permalink
Fix the upload shortcode, do not echo. Buffer and return content
Browse files Browse the repository at this point in the history
  • Loading branch information
sbrajesh committed Sep 15, 2016
1 parent 061d913 commit 6533937
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions core/shortcodes/mpp-shortcode-media-uploader.php
Expand Up @@ -58,8 +58,12 @@ function mpp_shortcode_uploader( $atts = array(), $content = '' ) {
$atts['context'] = 'shortcode'; //from where it is being uploaded,

$atts['view'] = $view;


ob_start();
//passing the 2nd arg makes all these variables available to the loaded file
mpp_get_template( 'shortcodes/uploader.php', $atts );


$content = ob_get_clean();

return $content;
}

0 comments on commit 6533937

Please sign in to comment.