Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
201 views
in Technique[技术] by (71.8m points)

php - Why my httpd-vhosts.conf isn't working? All my *.test still redirect to "It works!"

Just a question. I wanted to configure dnsmasq and apache2 to improve my local web development environment.

Everything works fine, until I configure the "httpd-vhosts.conf". I wanted to make it clear that in my "Sites" folder that's where I'm going to store all my projects.

Here is my http-vhosts.conf

Options Indexes MultiViews FollowSymLinks
AllowOverride All
Require all granted

<Virtualhost *:80>
VirtualDocumentRoot "/users/alix/www/sites/%1/wwwroot"
ServerName sites.test
ServerAlias *.test
UseCanonicalName Off
</VirtualHost>

The problem is that when i'm trying to access to *.test, they all still redirects me to Apache2's own index : "It Works". Why ?

I hope I made that clear, Thanks to all of you!

question from:https://stackoverflow.com/questions/65857257/why-my-httpd-vhosts-conf-isnt-working-all-my-test-still-redirect-to-it-work

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...