Hello. Sorry if this has been threaded before... or is in the wrong place.
I need information on setting up a local host.. but more like a dumb persons guide to setting up a local host on the mac.
Any offers please post.
54 68 65 42 65 61 72 4D 61 79
hey. Thanks a lot. That really does help. I can set up a local host on a pc but not mac, but that link helps. Thanks
yet another problem...
Has anyone had this problem...
localhost was working fine one day... the html file was in the webserver folder and i could type in localhost and my local site would pop up no problem...
then today... the html file still in the right place but when i type in localhost.. it pops up with the usual error page. all the files are still in the right folder but no local website.
ps. Im on a Mac
Check to make sure Apache is still running....
54 68 65 42 65 61 72 4D 61 79
This is getting stranger...
Apache is running...
If i was to type in any of these below, I get nothing.
http://***.***.*.5/ (* Being my computers I.P Numbers)
http://***.***.*.5/~Steve/ (* Being my computers I.P Numbers)
A copy of my files are in my local Sites folder and in my Library/WebServer folder.
I am on Mac OSX 10.5.5.
I have followed a lot of tutorials browsing the net but all dont explain any troublshooting, I found a lot of people in other forums whilst browsing that have / had this problem but no one replies with an explanation of how to fix the problem.
Im not knew to web development but I am knew to the server side of things and general stuff.
If someone knew how to fix this problem and write an explanation of how to here then maybe a lot of people can use this as a resource.
And I for one would forever be in the debt of whoever knows hot to solve this problem. It is a common problem.
Thank you in advance.
Just for the sake of argument how about http://localhost:8080 ? May need to look for the httpd.conf file - should be in the Apache/conf folder - and look through it for the root directory and port numbers....
54 68 65 42 65 61 72 4D 61 79
Thank you for the reply.
nope http://localhost:8080 doesnt work
The error page is as follows:
Failed to Connect
Firefox can't establish a connection to the server at localhost.
Though the site seems valid, the browser was unable to establish a connection.
* Could the site be temporarily unavailable? Try again later.
* Are you unable to browse other sites? Check the computer's network connection.
* Is your computer or network protected by a firewall or proxy? Incorrect settings can interfere with Web browsing.
I know that its not a firewall problem, my networks working fine, and all the web files are in the right places.
I admit though, I was messing around with terminal at the time and probably not sure what ive done.
It was working yesterday but not today... In that time I have done something with the terminal.
cannot find the httpd.conf file. ive searched it but no success...
any help would be appretiated and thanks for the replys so far..
help with Localhost for Dumb people like me...
Ok So heres what Ive post on Webmaster-Talk.
Ok So I went through the first tutorial at : http://www.devarticles.com/c/a/Apach...P-on-Mac-OS-X/
I took all the # off these...
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
restarted web sharing and Apache. went to http://localhost/ but still a Fail To Connect comes up. Theres an Index.html file in both Library/WebServer and MySites.
One thing I noticed was in System Preferences / Sharing / Web Sharing all the information has gone, nothing there at all also if i was to click the ? in the bottom right corner no help is there.
Id love to have this sorted before I install PHP and MySql but im reaching the end... not sure where to go? whats wrong? or what i am doing wrong?
Ive been through lots of online tutorials, all of which mainly telling me how to set this up, but not troubleshooting.
All the tutorials i have been through are :
Maybe these links could help others but due to my problem I cant find what I need, or either figure out what my problem is, this is really pushing my knowledge on server set ups. Im at the point of no return, help lol
I have reached the point of no return on getting my localhost to work.
No matter what I have tried nothing works, its great to have it working on my MacBook but I really need it on my iMac...
Now Im asking for services, can anyone help?
Also for anyone wishing to help me install PHP & MySql on my iMac..
Hope to hear from anyone soon
Last edited by TheBearMay; 01-06-2009 at 08:45 AM.
I'm developing on a macbook and I had difficulty initially getting the webserver running that comes with 10.5. I did manage to get all running though (except I still can't connect to mysql).
What I do remember is that you did have to have the Web Sharing checkbox checked in System Preferences / Sharing.
You said that all of the information was gone from there, does that include Web Sharing no longer being checked? If so check that again and see if that makes a difference.
The other thing I noticed is you typed Index.html. The apache config specifies the filename to run by default when a directory is requested, and it is usually index.html index.php. So if your file is Index.html and you are just typing in http://localhost then it will fail to find the file to display, and apache is typically setup to not allow directory listings, which is what your browser would try next.
Could you have accidentally renamed the file to Index.html while in the terminal?
More informative way to start Apache is through the terminal. Start X11, xterm, bash, or whatever you have... And type "httpd". See what it says?
You might have to switch to a super user before being able to start the server, for example if it says it can't access the log files. In that case write "su" and it will ask you for a super user password. If that doesn't work try "su <admin username>", and the same... You might have to first switch to a regular admin, and then to root with "su root", depending on your file access rights.
I had a similar problem and it said that Apache had not been shut down properly the last time, for some reason. And looks like Mac OS X's "web sharing" panel is totally useless, it tells you the server is started even if it failed, and doesn't show you any of the errors that occurred.
Last edited by scribbles; 03-07-2009 at 02:47 PM.
Oh yeah and you might want to start the process by making sure you shut down all the old versions of Apache first. So type "ps -A | less" and write down all the PID numbers for "httpd" processes that are running. Then type "kill <pid>" for each... And try to start your own server after this. This way you don't have other instances of the server somewhere on the background causing problems. You may have to be a super user first to do this.
Doesn't mac support `killall process name` rather than killing each process in turn?
Originally Posted by scribbles
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)