NYCPHP Meetup

NYPHP.org

[nycphp-talk] Quick little question - variable interpolation

Russ Demarest rsd at electronink.com
Thu Oct 17 15:11:23 EDT 2002


I believe

 $two = "= " . $one;

will do it.

    Good luck

Adam Fields wrote:

>This is one of those really easy questions that's difficult to search
>for because the search terms look like everything else.
>
>Is there an easy way to do simple variable interpolation on a string?
>
>For example, if I have:
>
>$one = '1';
>$two = '= $one';
>
>Is there a way to get $two to equal '= 1' (or whatever $one happens to
>contain, obviously)?
>
>  
>




More information about the talk mailing list