diff --git a/includes/kbe-core-functions.php b/includes/kbe-core-functions.php index dcab589..63429a3 100644 --- a/includes/kbe-core-functions.php +++ b/includes/kbe-core-functions.php @@ -123,8 +123,14 @@ function boxCloser(e) { */ function kbe_shortcode( $atts, $content = null ) { if ( !is_admin() ) { - $return_string = require dirname( __FILE__ ) . '/../template/kbe_knowledgebase.php'; + ob_start(); + + require dirname( __FILE__ ) . '/../template/kbe_knowledgebase.php'; wp_reset_query(); + + $return_string = ob_get_contents(); + ob_end_clean(); + return $return_string; } }