resolved. you need to enable output_buffering = on
or programtically set it in the first line of all the php codes
<?php ob_start(); ?>
In conclusion, am still working on the rest of the code to ensure workability and will get back here after i might have finish.
DynamicDrive: You guys are extremely wonderful