Xp Pro, PHP 5.2, Apache 2.2 STILL seeing source code
Posted: Mon Sep 28, 2009 10:59 pm
I'm trying to learn PHP since I need to build an application and the folks I'm helping are using a web server that doesn't support SQL Server.
SO, on my local machine In installed php, Apache, and MySQL.
I can run either http://localhost/info.php and it works fine, or http://127.0.0.1/info.php and IT also works fine. I even created a test.php that I can run THAT........
BUT, when I run an html file with php embedded I get the source code...... I've now wasted an entire <bleep> day going through web posts trying to find what configuration changes are needed. It STILL displays source code.......
And YES, in my httpd.conf I have
AddType application/x-httpd-php-source .phps
AddType application/x-httpd-php .php
PHPIniDir "D:/Program Files/PHP/"
LoadModule php5_module "d:\Program Files\PHP\php5apache2_2.dll"
And YES, they point (as near as I can tell) to the actual places where those files are.
I've stopped and started Apache service every time I've made a change......
The files I'm running are in the htdocs subdirectory (which I presume is being pointed to correctly since I can do the http://localhost/file... and it works.
I'm not sure what changes I need to make to php.ini since my installation only had 1 .ini file, not several to choose from. But, I found a location in the php.ini for doc_root, which seems like something that should point somewhere, but mine is just doc_root =
SO, can somebody out there tell me, in clear, unambiguous, idiot-proof terms, what I have to do to get PHP and Apache to successfully run the php embedded in the html? Once I have that I'll start the next battle - getting it to talk to MySQL.
SO, on my local machine In installed php, Apache, and MySQL.
I can run either http://localhost/info.php and it works fine, or http://127.0.0.1/info.php and IT also works fine. I even created a test.php that I can run THAT........
BUT, when I run an html file with php embedded I get the source code...... I've now wasted an entire <bleep> day going through web posts trying to find what configuration changes are needed. It STILL displays source code.......
And YES, in my httpd.conf I have
AddType application/x-httpd-php-source .phps
AddType application/x-httpd-php .php
PHPIniDir "D:/Program Files/PHP/"
LoadModule php5_module "d:\Program Files\PHP\php5apache2_2.dll"
And YES, they point (as near as I can tell) to the actual places where those files are.
I've stopped and started Apache service every time I've made a change......
The files I'm running are in the htdocs subdirectory (which I presume is being pointed to correctly since I can do the http://localhost/file... and it works.
I'm not sure what changes I need to make to php.ini since my installation only had 1 .ini file, not several to choose from. But, I found a location in the php.ini for doc_root, which seems like something that should point somewhere, but mine is just doc_root =
SO, can somebody out there tell me, in clear, unambiguous, idiot-proof terms, what I have to do to get PHP and Apache to successfully run the php embedded in the html? Once I have that I'll start the next battle - getting it to talk to MySQL.