Function is the combination of some code, those are not execute instantly. But when our necessary to call this function this another place, then we call this and work it.
Function are two types :
1. Built-in-function
2. User-defined-function
Built-in function are php own created function. That cannot be change. Several time we need to use this function. e.g phpinfo() is the built in function . If we use this function. This are automatically outputs a large amount of information about the current state of PHP. This includes information about PHP compilation options and extensions, the PHP version, server information and environment (if compiled as a module), the PHP environment, OS version information, paths, master and local values of configuration options, HTTP headers, and the PHP License.
Built in function are not enough for us. Several time we fell different problem. For remove this problem we need to create some function, these are called user-defined function. Now we need to know how to create a function.
Statement of a function:
function function_name()
{
echo ” How to develop web based world”;
}
