bool function_exists ( string $function_name )
<?php
function myfunc1() {
echo "hello myfunc1";
}
if (function_exists('myfunc1'))
echo "myfunc1() is defined." . "<br>";
else
echo "myfunc1() is not fefine." . "<br>";
if (function_exists('myfunc2'))
echo "myfunc2() is defined." . "<br>";
else
echo "myfunc2() is not fefine." . "<br>";
?>
myfunc1() is defined.
myfunc2() is not fefine.
欢迎光临 曲径通幽论坛 (http://www.groad.net/bbs/) | Powered by Discuz! X3.2 |