PHP exec – check if enabled or disabled

This will check if the function actually works (permissions, rights, etc):

if(@exec('echo EXEC') == 'EXEC'){
    echo 'exec works';
}

Leave a Comment