.php files
Hello,I've created a php file in textWrangler saved with .php extension on the desktop.But it does not open in the browser? Please help.
Related Article: All iMac files disappeared!
is a Mac OS X discussion thread by LovesPopstars that has 3 replies, was last updated 7 months ago and has been tagged with the keywords: imac, files, computer, system, preferences, itunes, music, photo, login, logout.
geekme
Junior Poster in Training
94 posts since Jan 2011
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0
Apache is installed on all macs. Do the following:
- Open a terminal
- type "cd /etc/apache2/"
- type "sudo pico httpd.conf", enter your password when requested
- find the line #LoadModule php5_module libexec/apache2/libphp5.so and remove the '#'
- save the file
- then go to system preferences, sharing and turn on 'Web Sharing' or turn it off and on if all ready on
- put the .php file in your sites folder.
In the web browser go to the following:
127.0.0.1/~YOUUSERNAME/nameOfYourFile.php
mikulucky
Junior Poster in Training
85 posts since Jan 2012
Reputation Points: 41
Solved Threads: 13
Skill Endorsements: 0