重複の可能性:
phpで関数を書く
私は次のコードを使用しています
echo 'Curl: ', function_exists('curl_version') ? 'Enabled' : 'Disabled';
これにより、有効または無効にできます
でも関数として関数名は _iscurl
それから私はそれを私のウェブサイトコードのどこにでも続くように呼ぶことができます
if (_iscurl()){
echo "this is enabled"; // will do an action
}else{
echo "this is disabled"; // will do another action
}
前の質問とほぼ同じで、allow_url_fopenが有効になっているかどうかを確認します
function_exists('curl_version')として使ってみません_iscurl()か?