Re: [PHP] Avoiding NOTICEs with list()

2005-01-25 Thread trlists
On 24 Jan 2005 James Kaufman wrote: > I just tried it with php 4.3.8 and it did not throw a NOTICE with @list. > I suppose you could try @explode as well as @list. Thanks. I was sure I had tried it with that but I will go back and check. -- Tom -- PHP General Mailing List (http://www.php.net

Re: [PHP] Avoiding NOTICEs with list()

2005-01-24 Thread James Kaufman
On Mon, Jan 24, 2005 at 03:54:45PM -0500, [EMAIL PROTECTED] wrote: > This construct: > > list($v1, $v2, $v3) = explode($sep, $string, 3); > > will generate NOTICE level errors if there are not enough parts of the > string to fill all the variables in the list. What I really want is > for

[PHP] Avoiding NOTICEs with list()

2005-01-24 Thread trlists
This construct: list($v1, $v2, $v3) = explode($sep, $string, 3); will generate NOTICE level errors if there are not enough parts of the string to fill all the variables in the list. What I really want is for list() to set the variables that have a corresponding array element, and then