Your test that works suggests that the function is "echo"ing its results,
and not actually returning its results.  To return its results the function
needs to end with

Function aFunction() {
  do something;
Return $resultstring;  // very last statement executed in function. <<<<<
}

This should allow

Echo "some string value".aFunction()."another string value";

To work,

Good luck,

Warren Vail
 


-----Original Message-----
From: Matt Matijevich [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 24, 2004 3:00 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: [PHP] a stupid question


[snip]
echo "Some text";
aFunction();
echo "Some more text";
[/snip]

What is printed out?

if aFunction() is returning the string "test" then this code: echo "Some
text".aFunction()."some more text"; should print out:

Some texttestsome more text

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to