|
Posted by Michael on 11/26/07 00:35
I would just like to correct myself, print is also a language construct
that *behaves* like a function.
- Michael
Michael wrote:
> Zach wrote:
>>
>> Why does Larry Ullman in his book "PHP for the world wide web"
>> have Print ("something");
>> in his book if it is Bulltwit?
> Because it's legal syntax.
>>
>> Zach.
>>
>> Onideus Mad Hatter wrote:
>>> On Wed, 21 Nov 2007 00:22:27 +0100, Zach <xx@xx.xx> wrote:
>>>
>>>> I am totally new to php
>>>> Question:
>>>> I am working on a Vista box.
>>>> *.php files are displayed OK by the browser,
>>>> however,
>>>>
>>>> print("something");
>>>>
>>>> does not lead to "something" being displayed.
>>>> What is the cause / what should I do?
>>>>
>>>> Zach.
>>>
>>> Try echo "something";
>
> print is a function, echo is a language construct. This means you can
> use print in complex expressions such as:
>
> $s ? print "true" : print "false";
>
> Echo can take multiple arguments such as:
>
> echo 'hello', ' ', 'world!';
>
> where as print can only take one,
>
> print('hello world!');
>
> - Michael
Navigation:
[Reply to this message]
|