使用批处理文件在后台启动Apache [英] Start Apache in background with batch file

查看:91
本文介绍了使用批处理文件在后台启动Apache的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

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

I'm writing a batch file that will start Apache, and the open http://localhost in the web browser. In its simplest form:

@start apache\bin\httpd.exe
@start http://localhost

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

This causes the batch file to run Apache, open the web page, and exit. However, the httpd.exe opens in its own terminal window, instead of opening hidden in the background. How can I make it open with no visible windows?

推荐答案

尝试一下:

@start /b "" apache\bin\httpd.exe

这篇关于使用批处理文件在后台启动Apache的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆