The most basic command, and probably the first you’ll learn when taking a look at PHP is “echo”. The first example in many books and online tutorials is the following. Create a file, give it an extension of “.php”, upload it to your server, and edit it like so:
<?php
echo ‘Hello World’;
?>
I hate Hello World examples, but this shows what we are doing pretty well. Basically the echo command will write out that phrase “Hello World” (the quotes will not be shown, the single quotes above are part of the code), so if you open that file using Firefox for example you should simply see the phrase.
This seems straightforward, but to really understand what’s happening, and to be able to work with PHP efficiently we need to dig a bit deeper to see what really happens when we echo something.

