Find out if function has any output with php
- by Keith Donegan
Quick one for you guys.
Say I have a function that outputs a string:
function myString()
{
echo 'Hello World';
}
How would I go about testing to see if the function outputs any data?
if(myString() ==''){
echo ''Empty function;
}