Issue
So, I love Wamp. It's great for development. The only downside is that in wamp, I have to code everything to use "localhost/projectname/" as a base, but on my actual site, everything has the base of just "/".
Is there a way to use wamp where it treats localhost has your website url?
Solution
here's how I'm doing :
I'm editing my httpd.conf file and append a virtual host at the bottom of it (in the dedicated lines) each time I want to add a new local website :
<VirtualHost *:80> DocumentRoot "C:/wamp/www/fake" ServerName fakesite </VirtualHost>
And I tell windows to point the local host address (127.0.0.1) from the hostname that I defined (fakesite in the example):
I'm using windows and I just edit the following file :
X:\Windows\System32\drivers\etc\hosts
and append a new line as follow :127.0.0.1 fakesite
note : you'll need to restart wamp after edition config files.
This way and if everything went right you'll just need to type fakesite/xxx
to reach the following physical folder : c:/wamp/www/fake/xxx
Answered By - vdegenne
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.