Can't serve PHP pages on Mac

Problems with the Mac OS X version of XAMPP, questions, comments, and anything related.

Can't serve PHP pages on Mac

Postby icue » 03. August 2011 15:13

Hi. I am pulling out what little hair I have left trying to figure this out so I could really do with some help.

I know very little about servers, and this is my first time trying to learn PHP and mysql. I have installed XAMPP and as far as I know,
everything is installed properly, and all passwords and security is set. If I put http://localhost/xampp/index.php into Safari nav bar the
welcome page is displayed so I assume PHP is being served. However, I can't get any of the PHP tutorial files I create to work. I either get
Object not found Error 404 or the PHP code is displayed in the browser window. I assume I must be putting my files in the wrong place
and they are not being accessed by the web server. Could someone please tell me where I am going wrong.

I have a folder (my_site) in the htdocs folder in which I have all my files. Should I be placing my files somewhere else?

Any advice would be much appreciated. Please don't get too technical as I may not understand.

Posts: 3
Joined: 03. August 2011 13:30
Location: London
XAMPP Version: 5.6.14
Operating System: Windows Vista

Re: Can't serve PHP pages on Mac

Postby algo160 » 17. January 2012 01:06

im sorry you have that problem, i'll try to help

first go to your Apps folder

then place you file in xampp>xampp_files (?) > htdocs > <place file here>
or if you want it simple place it in your sites folder, and it will be localhost/~<username>/<file>

if you need any php help feel free to ask, i learned php at age 8 :?
Posts: 3
Joined: 16. January 2012 05:20
XAMPP Version: 5.6.14
Operating System: Mac Operation System X

Return to XAMPP for Mac OS X

Who is online

Users browsing this forum: No registered users and 2 guests