laravel 运行php artisan serve时如何退出命令流?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/26054141/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-08 16:45:24  来源:igfitidea点击:

How to exit the command stream when running php artisan serve?

laravel

提问by funguy

I am suing command prompt on windows. When I run php artisan serve the command prompt enters some kind of command stream where you can not use the command line anymore. How to exit this stream so that I could use the command line? Also, does this mean that exiting this mode will stop serving the app?

我在 Windows 上起诉命令提示符。当我运行 php artisan serve 时,命令提示符会输入某种命令流,您将无法再使用命令行。如何退出此流以便我可以使用命令行?另外,这是否意味着退出此模式将停止为应用程序提供服务?

回答by fajarhac

php artisan servemeans you create a server. as long as this server running you can view your created website in browser at http://localhost:8000. what you said as 'some kind of command stream' is things that server is serving. Yes exiting command prompt will terminate the php artisan servemeans when you access http://localhost:8000there will no website to be seen anymore.

php artisan serve意味着您创建了一个服务器。只要此服务器运行,您就可以在浏览器中查看您创建的网站http://localhost:8000。你所说的“某种命令流”是服务器正在服务的东西。是的,退出命令提示符将终止该php artisan serve方法,当您访问时http://localhost:8000,将不再看到任何网站。

You can terminate the server by Ctrl+c ORjust open another cmd prompt and keep php artisan running

您可以通过 Ctrl+c 终止服务器,或者只需打开另一个 cmd 提示符并保持 php artisan 运行

回答by codex

i had the same problem...i simply used xampp shell to run Laravel and used Windows Cmd to perform the rest of my Laravel Commands

我遇到了同样的问题……我只是使用 xampp shell 来运行 Laravel 并使用 Windows Cmd 来执行其余的 Laravel 命令

回答by Harshal Doshi Jain

Simply use Ctrl+C.
It will come out to prompt state.

只需使用Ctrl+ C
它会出来提示状态。