10-05-2009, 06:00 PM #1
I want to activate PHP to read downloaded files
- Member Since
- Jan 13, 2007
- Mac Mini 2009 2G Ram OS 10.5.8, B&W G3 10.3.9 and 9.2.2, Pismo 10.3.9
I've installed MAMP. I've put the MAMP control widget into the widget library but I don't understand the instructions about "put HTML and PHP files in the htdocs folder". I'm not working with MY files. I'm trying to get some intelligence from the files I've downloaded. So… I want to READ the files. How do I accomplish that? Wonder why Apple would install this stuff and then make it so hard to use or even get to? Thanks for reading this. Dan
10-12-2009, 02:39 PM #2
- Member Since
- Dec 13, 2007
- United States of America
- 2.1GHz MacBook with 4GB RAM, Mac OS X 10.6, iLife and iWork ‘09
When you say that you want to "read" the PHP files, do you mean that you want to read their source code (which you can do with TextEdit) or that you want to view them as they would be served by a Web server?
If it's the latter, you basically need to do three things. First, you need to enable PHP. Next you have to enable Apache, and finally you simply place the PHP files in the right spot and view them in your Web browser.
Here are some very in-depth instructions that cover each step in detail. One thing that I didn't see him mention is that you can also use a command-line text editor like vim or nano if you're comfortable with it instead of downloading a new application (just be sure to run it as root so that you can save). Also, he mentions putting the documents in Macintosh HD:Library:WebServer:Documents, but you can put them in your personal Sites folder as well. Then to access them from your browser, go to http://127.0.0.1/~username and you'll see a list of files in your Sites folder (if you get an error, make sure you've enabled Web Sharing in System Preferences).
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
By Mbengi Bongi in forum Web Design and HostingReplies: 5Last Post: 06-26-2011, 10:56 AM
By ben3001 in forum OS X - Apps and GamesReplies: 3Last Post: 01-02-2008, 06:39 AM
By rypod81 in forum Switcher HangoutReplies: 5Last Post: 07-08-2005, 03:31 PM
By rypod81 in forum Apple NotebooksReplies: 3Last Post: 07-08-2005, 03:25 PM
By fabio in forum OS X - Development and DarwinReplies: 5Last Post: 07-16-2004, 04:48 PM