php echo

To put a string into the HTML of a PHP-generated page, use echo. While it looks— and for the most part behaves—like a function, echo is a language construct. This means that you can omit the parentheses, so the following are equivalent:

echo “Printy”;
echo(“Printy”); // also valid

You can specify multiple items to print by separating them with commas:

echo “First”, “second”, “third”;

Leave a Comment