How to debug what is returned via RETURN

Dear All

I have the following code:

$myEmail = '';
$db = JFactory::getDbo();
$query = $db->getQuery(true);
$query->select('email')->from('anmeldung');
$db->setQuery($query);
$myEmail = $db->loadResult();
return $myEmail;

How can I check what actually is returned in $myEmail? Is there a way to use the ECHO command and show this in the browser? Or any other way?

Thanks and best
René
 
You can comment your return and check the result with var_dump
Code:
//return $myEmail;
var_dump ($myEmail);exit;
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top