Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
Apple Computing Products:
macOS - Operating System
Apache and PHP
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="giszzmo" data-source="post: 1300655" data-attributes="member: 216001"><p>I'm trying to run a .php file using localhost web server and i can't get it to work. I have OS X 10.6.8. I believe Apache and PHP are already installed. I have enabled File Sharing and Web Sharing under System Preferences. When I type, localhost, into my browser, I get "It works!" So I got that part working. I have placed my .php file under /myusername/Sites/file.php. So, when I type localhost/myfile.php into my browser, shouldn't I get the output of that code that I put into my .php file? Instead, I get </p><p></p><p>"Not Found The requested URL /hello.php was not found on this server." </p><p></p><p>I think I'm missing a step. Can anyone help? </p><p></p><p>Thanks</p></blockquote><p></p>
[QUOTE="giszzmo, post: 1300655, member: 216001"] I'm trying to run a .php file using localhost web server and i can't get it to work. I have OS X 10.6.8. I believe Apache and PHP are already installed. I have enabled File Sharing and Web Sharing under System Preferences. When I type, localhost, into my browser, I get "It works!" So I got that part working. I have placed my .php file under /myusername/Sites/file.php. So, when I type localhost/myfile.php into my browser, shouldn't I get the output of that code that I put into my .php file? Instead, I get "Not Found The requested URL /hello.php was not found on this server." I think I'm missing a step. Can anyone help? Thanks [/QUOTE]
Verification
Post reply
Forums
Apple Computing Products:
macOS - Operating System
Apache and PHP
Top