Is this a php variable variable bug? -
is there logical explanation this?
<?php $$a = 'hello world'; echo $$a; //displays hello world echo $$aa; //displays hello world echo $$aaa; //displays hello world ?>
if try
$$a = 'hello world'; echo $$a; //displays hello world echo $$aa; //displays hello world echo $$aaa; //displays hello world die( "<pre>" . print_r( get_defined_vars(), true ) . "</pre>" );
you can see has registed variable no name yes, according php's naming conventions, bug
Comments
Post a Comment