Re: Help with functions()
| From: | Tracy Finifter Rotton | Date: | Thu, 21 Nov 2002 00:48:18 +0000 |
| Subject: | Re: Help with functions() | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-125360@lists.php.net to get a copy of this message | ||
Try:
$meat = testfunction ($var1, $var2, $var3, $var4);
echo $meat;
Or, alternatively,
print (testfunction ($var1, $var2, $var3, $var4));
hope this helps.
--t
On 11/20/02 8:40 PM, "Beauford 2002" <beauford.2002@rogers.com> wrote:
> Hi,
>
> I have form that a user would input information and that info is sent to
> a function, but I need to be able to return a result of this function
> and is where I am having a problem.
>
> For example:
>
> testfunction($var1, $var2, $var3, $var4); //the form fills these
> values.
>
> echo $meat;
>
> function testfunction($a, $b, $c, $d) {
>
> The $meat of the function goes here;
>
> Now I need to return the result of $meat;
>
> return $meat;
> }
>
> This does not work. I'm new to funtions and obviously missing something,
> but I haven't been able to find a good tutorial on this. The PHP manual
> isn't much help.
>
> Any help is appreciated.
>
>
--
Tracy F. Rotton
tracy@taupecat.com
http://www.taupecat.com/
"... I like the 49ers because they're pure of heart,
Seattle because they've got something to prove,
and the Raiders because they always cheat."
-- Lisa Simpson, "Lisa the Greek"