问题
I need to run php artisan config:clear
on my app that is online, the only issue is that I have only the FTP credentials and DB, and not the SSH to run on the terminal, how can I run this command without the terminal?
Already tried looking on the forum and didn't found any question related with my issue but didn't found any answer for it.
回答1:
You can call the artisan command from anywhere in your PHP code block.
$exitCode = Artisan::call('config:clear');
More info can be found here https://laravel.com/docs/5.4/artisan#programmatically-executing-commands
回答2:
That artisan command is only a helper to let you clear out the cached files.
You should be able to clear the config cache yourself, by removing the file config.php from folder /bootstrap/cache/ in your project.
来源:https://stackoverflow.com/questions/44097969/run-config-clear-on-browser