使用批处理文件在后台启动Apache

she*_*hea 1 windows apache batch-file

我正在编写一个批处理文件,它将启动Apache,并http://localhost在Web浏览器中打开.最简单的形式:

@start apache\bin\httpd.exe
@start http://localhost
Run Code Online (Sandbox Code Playgroud)

这会导致批处理文件运行Apache,打开网页并退出.但是,httpd.exe在自己的终端窗口中打开,而不是在后台隐藏打开.如何在没有可见窗口的情况下打开它?

End*_*oro 6

试试这个:

@start /b "" apache\bin\httpd.exe
Run Code Online (Sandbox Code Playgroud)