function write($text) //定义function write()函数
{
print($text); //打印字符串
}
function writebold($text) //定义function write()函数
{
print($text); //打印字符串
}
$myfunction = write; //定义变量
$myfunction(你好!
); //由于变量后面有括号,所以找名字相同的function函数
print(
\n);
$myfunction = writebold; //定义变量
$myfunction(再见!); //由于变量后面有括号,所以找名字相同的function函数
print(
\n);
?>
