开发者

PHP, Extract function call name with regex

开发者 https://www.devze.com 2023-02-27 06:14 出处:网络
$textvar = \"Text(foo): \" . func1(\"foo (bar)\") . func2 ($some_arg); What regex can I use to extract the above function names to verify
$textvar = "Text(foo): " . func1("foo (bar)") . func2 ($some_arg);

What regex can I use to extract the above function names to verify the existanc开发者_Go百科e of these functions?


How about this?

<? if(function_exists($function_name)) {
    //do something; 
}
?>
0

精彩评论

暂无评论...
验证码 换一张
取 消