RE: [PHP4BETA] while/each issue on PHP/4.0RC2-dev
| From: | Dan Larsson | Date: | Wed, 12 Apr 2000 08:46:12 +0000 |
| Subject: | RE: [PHP4BETA] while/each issue on PHP/4.0RC2-dev | ||
| References: | 1 | Groups: | php.version4 |
| Request: | Send a blank email to php-version4+get-13440@lists.php.net to get a copy of this message | ||
| -----Original Message-----
| From: Rasmus Lerdorf [mailto:rasmus@php.net]
| Sent: Wednesday, April 12, 2000 10:13 AM
| To: Dan Larsson
| Cc: Php4beta (E-mail)
| Subject: Re: [PHP4BETA] while/each issue on PHP/4.0RC2-dev
|
|
| Is $server actually an array?
Yes it is. The funny thing is that besides the errormessage
the page works.
Even if I enclose the code with if(is_array[$server]) { ... }
the message appears.
| > Errormessage:
| > -------------
| > Warning: Cannot use a scalar value as an array in
| functions.inc on line 156
| >
| > functions.inc starting on line 156
| > ----------------------------------
| > while (list($key, $value) = each($server))
| > {
| > if (empty($val['hostname']))
| > unset($server[$key]);
| > }
Regards
------------
Dan Larsson