ID: 14160
Updated by: jan
Reported By: [EMAIL PROTECTED]
Old Status: Feedback
Status: Open
Bug Type: Arrays related
Operating System: Windows 2000
PHP Version: 4.0.6
New Comment:

Can't reproduce this on FreeBSD 4.2-Stable and PHP 4.1.0RC3 as cgi or RC2 as mod_php. 
maybe a windows thingie ?


Previous Comments:
------------------------------------------------------------------------

[2001-11-21 10:22:24] [EMAIL PROTECTED]

Sorry, of course I meant

http://phpuk.org/~james/php-4.1.0RC3-win32.zip



------------------------------------------------------------------------

[2001-11-21 10:20:43] [EMAIL PROTECTED]

Works for me:
[chroot] mfischer@ficken:~/src/php/bugtest$ php
<?
$translations=Array();                                                                 
                  $translations["Register Now for Free!"]="¡Regístrate ya gratis!";    
                                    echo $translations["Register Now for Free!"];
?>
X-Powered-By: PHP/4.0.6-dev
Content-type: text/html

¡Regístrate ya gratis![chroot] mfischer@ficken:~/src/php/bugtest$ 

Hmm.... probably dumb question, are you really running 4.0.6?

Can you try latest RC

http://www.php.net/~zeev/php-4.1.0RC3.tar.gz

Feedback.

------------------------------------------------------------------------

[2001-11-21 10:15:34] [EMAIL PROTECTED]

$translations=Array();
$translations["Register Now for Free!"]="¡Regístrate ya gratis!";
echo $translations["Register Now for Free!"];


will print nothing, or an error about undefined index, depending on your error 
settings in php.ini. As I said before, removing the exclamation mark in the key fixes 
the problem.

------------------------------------------------------------------------

[2001-11-21 10:08:25] [EMAIL PROTECTED]

Works for me on 4.0.6 , Linux.

Please give the shortest reproduceable script.

Feedback.

------------------------------------------------------------------------

[2001-11-21 10:04:02] [EMAIL PROTECTED]

if you have an array where the key is a string like
$arrayname["a string here!"]. You will not be able to pull the value for that key from 
the array. Removing the exclamation mark in the key fixes this bug.

------------------------------------------------------------------------



Edit this bug report at http://bugs.php.net/?id=14160&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to