function.php

<?php
function add_salutation( $name, $title = "Mr." ) {
  return "Dear $title $name";
}
?>

<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Function example</title>
    <meta charset="utf-8">
  </head>
  <body>
    <?php
    print add_salutation("Jones");
    print "<br />";
    print add_salutation("Smith", "Ms.");
    ?>
  </body>
</html>