Re: Class Static variables in double quoted string or heredoc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2008-04-25 at 10:14 -0600, Nathan Nobbe wrote:
> On Fri, Apr 25, 2008 at 10:02 AM, Jason Pruim <japruim@xxxxxxxxxx> wrote:
> 
> >
> > On Apr 25, 2008, at 11:56 AM, Nathan Nobbe wrote:
> >
> >  On Fri, Apr 25, 2008 at 9:50 AM, Leurent Francois <131.php@xxxxxxxxxxxx>
> >> wrote:
> >>
> >>  Is there any hope that
> >>> echo "Welcome {session::$user_info['user_name']}";
> >>>
> >>> will work someday, if not, is there a simple reason i'm missing ?
> >>>
> >>
> >>
> >> actually, if you see my post from the other day, this is something that
> >> *was* supported in php-5.2.4.  i dont know why its not working in 5.2.5;
> >> ive
> >> also checked 5.2.6_rc3 and its not working there either.  i have written
> >> some phpt tests and run them on a 5.2.4 install and a 5.2.6_rc3 install;
> >> you
> >> can find the details on a post to the php-qa list from a couple of days
> >> back
> >> (that i posted after a lack of interest from the php-general list :O)
> >>
> >> http://marc.info/?l=php-qa&m=120901795414161&w=2
> >>
> >
> > is there a reason why that would work better then: echo "Welcome
> > {$_SESSION['user_info']['user_name']}";?
> >
> > Just curious :)
> 
> 
> i think the question is more along the lines of why cant static references
> be embedded within double quoted strings like class instances (and
> indirectly the issue i mentioned earlier this week, which affords a
> workaround), as in

I think the real question is... why do you guys want to stick a whole
scripting engine into double quotes? There's this thing in PHP, it's
called the concatenation operator... read about it sometime.

*shakes his head* *points at the cavemen* *laughs* Hah hah!

:^

Cheers,
Rob.
-- 
http://www.interjinn.com
Application and Templating Framework for PHP


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux