I have a php file that when run, creates a search display page. Since this is part
of a large library I am hoping to include files rather than create more large functions.
I saw this method and it works, but it leaks all of the text out before the actual
page displays. Is there a way to avoid this? Here is an example:
public function fsc_search_display()
{
ob_start();
include("fsc/modules/fsc_search.php");
$output = ob_get_contents();
return ['html' => $output];
}
I added this code to core/packages/localapi/api/main.php
My template contains:
{vb:data result, localapi:main, fsc_search_display}
{vb:raw result.html}
Does anybody know of a way to correct this problem?
Thank you in advance,
RIck
Devami...