PHP Output Buffering with WordPress

Use this to buffer output of a function. Useful in plugin development when shortcode displays are to be created in conjunction with custom post modules. In this snippet, the shortcode contents are being called by the include and the buffer output.

Code Markup
function buffered_function() {
    include 'path/to/shortcode.php';
    return ob_get_clean();