Re: f()["DATA"]

From: Date: Mon, 05 Mar 2012 00:06:47 +0000
Subject: Re: f()["DATA"]
References: 1  Groups: php.webmaster 
Request: Send a blank email to php-webmaster+get-13159@lists.php.net to get a copy of this message
On Sun, Mar 4, 2012 at 11:53 PM, Бадмацыренов Вячеслав <badvic1@yandex.ru> wrote: > Hello, > > i just have question about this code: > > <?//-------------------------------------- ban_data ---------------------------------------- > if(!function_exists('f')){ > function f(){ >        $aRes["DATA"]="data"; >        return $aRes;}} > echo f()["DATA"]; > ?> > and this error out: > Parse error: syntax error, unexpected '[', expecting ',' or ';' > in /chroot/www/page.php on line 15 > > so, will php support this feature (maybe in a future)? It's supported as of PHP 5.4. > thanks > > -- > PHP Webmaster List Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.webmaster (#13159) next »