NYCPHP Meetup

NYPHP.org

[nycphp-talk] Variable composition: ${'foo'.$i}

Jeff Slutz jeff at jeffslutz.com
Mon Jan 27 18:46:18 EST 2014


I've known it by the term variable variables.

http://www.php.net/manual/en/language.variables.variable.php

JS

--
Jeff Slutz
JSLEUTH LLC
jeff at jeffslutz.com


On Mon, Jan 27, 2014 at 4:43 PM, Ron Guerin <ron at vnetworx.net> wrote:

> Is the only name I've found for this:  ${'foo'.$i}
>
> Which, if $i is 2, gives the value of the variable $foo2
>
> Since "variable composition" only has one hit in Google though, there's
> got to be another name for it.  Anyone know what that might be?
>
> - Ron
> _______________________________________________
> New York PHP User Group Community Talk Mailing List
> http://lists.nyphp.org/mailman/listinfo/talk
>
> http://www.nyphp.org/show-participation
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nyphp.org/pipermail/talk/attachments/20140127/ffac9348/attachment.html>


More information about the talk mailing list