> $name = ab;
> Notice: Use of undefined constant ab - assumed 'ab' in
> c:\inetpub\wwwroot\sdd\pages\name&age.php on line 3

<rant>
Honestly, do you read the error messages or do you just post them to the
list? You need to stop using us for the easy answer and do a little
looking yourself. For example... when I see that error, I'm going to ask
my self "why is PHP thinking ab is a constant?" Do I mean it to be a
constant? If so, I must of forgot to define() it somewhere. If it's not
supposed to be a constant, what is it supposed to be? An integer... well
a and b don't make very good integers, so probably not. It's supposed to
be a string, right? So why is PHP thinking it's a constant? At this
point, if I didn't know what was going on, I'd go to the manual and read
the chapter on variable types and the sections on constants and
strings... to learn what the difference is. I'll guarantee that if you
actually read those sections, you'd realize... on your own... (imagine
that) that strings have to be surrounded by quotes... either single or
double (the section will even explain the difference). So now you'd know
the answer, you found it yourself, you maybe learned a few other things
as you read, and I bet you would have gotten your answer a lot faster
than waiting for answers on a mailing list...
</rant>

---John W. Holmes...

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/



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

Reply via email to