Reputation: 941
I have a problem with MAMP, when I try and visit a url such as http://localhost/discoversolar
it does not work.
However if I visit http://streetcrime/discoversolar
it works. I may have previously set up an alias or something but I have no idea how or where I did this.
Can anyone point me in the direction of changing this back to localhost so that it works?
I have looked in /etc/hosts
, /Applications/MAMP/conf/apache/httpd.conf
and /Applications/MAMP/conf/apache/extra/httpd-vhosts.conf
but failed to find anything.
In /Applications/MAMP/conf/apache/httpd.conf
it even states ServerName localhost:80
Thanks for any help!
Upvotes: 1
Views: 18240
Reputation: 131
I was just going through this issue. I couldn't get my localhost to populate and I remembered editing the HOSTS file in /etc/hosts ..
I had commented the following out:
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
fe80::1%lo0 localhost
Add into your host file and it should work :)
Hope this helps! Regards!
UPDATE:
MAMP works via port 8888 .. Try
http://locahost:8888
Upvotes: 1
Reputation: 2094
probably this is what you have lost
Open BBEdit or TextWrangler (a free, cut-down version of BBEdit available from www.barebones.com). From the File menu, select Open Hidden. In the Open dialog box, select All Files from the Enable drop-down menu. Then navigate to Macintosh HD:private:etc:hosts, and click Open.
see http://foundationphp.com/tutorials/vhosts_leopard.php
hope this helps
Upvotes: 0