Home  >  Article  >  Backend Development  >  Function_PHP Tutorial

Function_PHP Tutorial

WBOY
WBOYOriginal
2016-07-20 10:59:49769browse

​ A function can be defined using the following syntax
function foo ($arg_1, $arg_2, ..., $arg_n) {
echo "Example function.";
return $retval;
}
Any valid PHP code can appear in a function, even other function or class definitions.
Functions must be defined before they are referenced.

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/445573.htmlTechArticleA function can be defined using the following syntax: function foo ($arg_1, $arg_2, ..., $arg_n) { echo Example function.; return $retval; } Any valid PHP code can appear in...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn