View Single Post
  #3 (permalink)  
Old January 13th, 2004, 12:35 AM
richard.york's Avatar
richard.york richard.york is offline
Wrox Author
 
Join Date: Jun 2003
Posts: 1,706
Thanks: 0
Thanked 6 Times in 6 Posts
Default

What you're doing is right but the syntax is a bit off.

The blueprint for echo is as follows:

echo [expression[, expression[, expression[, ...]]]]

So this being the case the following will work

<?php

// parenthesis are optional with echo.
// Works

echo "Hello, ", "world!";

// If you do include parenthesis, then this is the syntax
// Works

echo ("Hello, "), ("world");

// OR

echo ("Hello, "),
     ("world!");

// Echo isn't a function, but a language construct, and as per the blue print above
// This won't work

echo ("Hello, ", "world!");

?>

http://www.php.net/echo

: )
Rich

:::::::::::::::::::::::::::::::::
Smiling Souls
http://www.smilingsouls.net
:::::::::::::::::::::::::::::::::