Re: Returning variable and array from function

From: Date: Tue, 12 Jun 2007 10:17:20 +0000
Subject: Re: Returning variable and array from function
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-28064@lists.php.net to get a copy of this message
Gustav Wiberg wrote:
I think I have done this before but I can't remember how I did... I want to return one variable ($htmlReport) and one array from a function I'd like to like this: return $htmlReport, $res; but get the error: Parse error: syntax error, unexpected ',' in C:\www\test\timeweb\classes\reports.php on line 2745
Yeah, that's not valid PHP. Return it as as array... return array($htmlReport, $res); -Stut

« previous php.windows (#28064) next »