Issue
I'm trying to create a virtual host on my MAMP setup so I can access http://api.localhost for a PHP API I'm trying to build with Slim. Here's the code I've appended to my httpd.conf
file:
Name VirtualHost 127.0.0.1
<VirtualHost 127.0.0.1>
DocumentRoot "/Applications/MAMP/htdocs/slim"
ServerName api.localhost
</VirtualHost>
When I restart the server and try to start it up again with this new configuration, it simply won't load. I commented out the new code and it loads fine. Any ideas?
Solution
try to use this line
<VirtualHost *:80>
instead of yours
and I think you can remove the first line too...
Answered By - Simon Berka
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.