Well there is 2 ways to do this. Globaly or just one page.
If your going to do one page like i needed. On my forumhome page. I just opened index.php and added the following line just before the navbar and header veriables.
PHP Code:
ob_start();
All the php code you want here
$html = ob_get_contents();
ob_end_clean();
Then i just added $html in my forumhome template and it worked perfect. For those who need it on all pages. Just add the above code in your php_include_start template.