Skip to content

Instantly share code, notes, and snippets.

@phpfiddle
Created September 9, 2017 01:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save phpfiddle/4b28378b9bccdb8abbd33311f3efd8ce to your computer and use it in GitHub Desktop.
Save phpfiddle/4b28378b9bccdb8abbd33311f3efd8ce to your computer and use it in GitHub Desktop.
[ Posted by Jose ] Pass values to parameters in a PHP function
<?php
function greeting($name, $age) {
return "<h1>Hello " . $name . " you are " . $age . " years old today. Happy Birthday!!</h1>";
}
echo greeting('Billy', '146');
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment