Re: mixed datatype

From: Date: Mon, 28 Jan 2002 17:46:11 +0000
Subject: Re: mixed datatype
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-82441@lists.php.net to get a copy of this message
<? function MyFunc($item, $args="") { extract((isset($args)?$args:array())); return("$item, $first_arg$second_arg$third_arg"); } //call MyFunc() echo MyFunc("hi there", array( "first_arg" => "my name ", "second_arg" => "is ", "third_arg" => "Jim.", )); // this will print // "hi there, my name is Jim." ?> Hope this helps. Jim Lucas ----- Original Message ----- From: "charlesk " <charlesk@netgaintechnology.com> To: <php-general@lists.php.net> Sent: Monday, January 28, 2002 8:23 AM Subject: [PHP] mixed datatype > How do you make a function like > bool session_register (mixed name [, mixed ...]) > > What does the function look like that it can take unlimited arguments? > > Charles Killmer > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > >

« previous php.general (#82441) next »