Ryan A wrote:

Hi again,
One last question as am a bit confused, using this method:

$s = str_replace(
array('$firstname', '$lastname', '$sitename', '$message'),
array($firstname, $lastname, $sitename, $message),$s);

do I *have to* pass 4 arguements?


you can set default values (eg an empty string) to cover that scenario. I can aslo offer you a third alternative to the very good suggestions already offereed by Marek and Sokolewicz; printf();

--
Raditha Dissanayake.
------------------------------------------------------------------
http://www.radinks.com/print/card-designer/ | Card Designer Applet
http://www.radinks.com/upload/ | Drag and Drop Upload


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



Reply via email to