In this example, the function printBR() "expects a string, so the variable name $txt is placed between the parentheses when the function is declared. Whatever is passed to printBR() will be stored in this $txt variable. Within the body of the function, line 3 prints the $txt variable, appending a <br /> element to it." (135) A programmer can use this function instead of the built-in print() and save the bother of typing the <br /> element. Pretty cool, huh?
<?php
function printBR($txt) {
echo $txt."<br />";
}
printBR("This is a line.");
printBR("This is a new line.");
printBR("This is yet another line.");
?>