Hi,
this is just to add a behavior that I haven't understud at first place.
ob_get_flush actually returns the content of the buffer as a text but also it sends the buffer back to the browser so that it's displayed on user screen.
Use ob_get_clean if you do not want the buffer to be send to the user