* Thus wrote Greg Donald ([EMAIL PROTECTED]): > On Fri, 2004-05-21 at 08:37, Richard Davey wrote: > > Absolutely - and one of the best features of constants is their scope > > - being global in nature you can use them ANYWHERE which is very handy > > indeed! > > ANYWHERE except in code you plan to eval(). > > Funny how get_defined_constants() knows about all your CONSTANTS, but > eval() doesn't.
Works fine: define('A_DEFINE', 'This is defined value'); eval('echo A_DEFINE;'); You were trying to do this: $val = "Defind {A_DEFINE}"; echo $val; Which wont work. Only variables can be expanded inside strings. Curt -- "I used to think I was indecisive, but now I'm not so sure." -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php