chinmay.sahoo
New member
Functions can also be used to return values.
The output of the code above will be:
1 + 16 = 17
The PHP $_GET and $_POST variables are used to retrieve information from forms, like user input.
<html>
<body>
<?php
function add($x,$y)
{
$total = $x + $y;
return $total;
}
echo "1 + 16 = " . add(1,16);
?>
</body>
</html>
The output of the code above will be:
1 + 16 = 17
The PHP $_GET and $_POST variables are used to retrieve information from forms, like user input.