开发者

where should i implement a "default redirect" in apache

开发者 https://www.devze.com 2023-01-10 16:15 出处:网络
Currently i have 3 separate vhost filesdefault,staging,a开发者_如何学Cnd devel. I want www.example.com and example.com to use the default vhost. I want staging.example.com to use the staging vhost. He

Currently i have 3 separate vhost files default,staging,a开发者_如何学Cnd devel. I want www.example.com and example.com to use the default vhost. I want staging.example.com to use the staging vhost. Heres where the problem im having is; i want anything else ex. anything.example.com or else.example.com to use the devel vhost. what is the best way to accomplish this?


The first host Apache reads will be the default one.

I would therefore recommend inserting the default one on httpd.conf as this file is read first and then load up all VHosts as you wish.

0

精彩评论

暂无评论...
验证码 换一张
取 消