|
Posted by Jochem Maas on 07/25/05 15:27
Richard Lynch wrote:
> On Sun, July 24, 2005 11:39 am, Dotan Cohen said:
>
>>On 7/24/05, Bruce Gilbert <webguync@gmail.com> wrote:
>>
>>>I am well versed in coding with xhtml which requires all lower case
>>>and am pretty much a newbie at PHP so that is why I am asking this
>>>question.
>>>
>>>is this acceptible
>>>
>>>if ($_post [sender_email] == "") or does at have to be if ($_POST
>>>[sender_email] == "")
>>>
>>>in short, do uppercase and lowercase always have the same meaning.
>>>
>>>thx,
>>>
>>
>>PHP is case-sensitive. UppERCase is NOT the same as uppercase. HTML is
>>not case sensitive only because browsers are forgiving.
>
>
> PHP variables are case-sensitive.
>
> PHP FUNCTIONS are not.
>
> You're on your own figuring out if class names/methods are/aren't
> case-sensitive this week. :-v
1. classname are case-insensitive (at least in all the builds I have running)
but since 5.0.1 (IIRC) the engine honors your case when using get_class(),
in the past the class name was always returned lowercase. so:
php -r 'class Test {} $t = new Test; if ($t instanceof test) { echo "yeah!\n"; } echo get_class($t),"\n";'
will echo:
yeah!
Test
2. methodnames are the same as functionname with regard to case-sensitivity
3. constants (and class constants) are case sensitive.
....somebody beat me with a virtual stick if I am wrong!
>
Navigation:
[Reply to this message]
|