using constants

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
Am I right in thinking there is no way to include a constant in a double
quoted string, ie. like you can do "you are $name !" with variables?
I can't find any mention of how to reference constants in the php help
file, I get the impression the only way is to concatenate them, eg.
"you are ".NAME." !"

Re: using constants

Quoted text here. Click to load it

Right, variable interpolation performed on double-quoted strings
doesn't parse constants.

$email = str_replace('sig.invalid', '', $from);

Anonymous (1984 IOCCC winner):
int i;main()"];read('-'-'-',i+++"hell\
o, world!\n",'/'/'/'));}read(j,i,p)

Re: using constants

Marty Fremen escribió:
Quoted text here. Click to load it

See also sprintf().

-- - Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web:
-- Mi web de humor satinado:

Site Timeline