View Full Version : [Resolved] PHP in HTML

Jan 6, 2012, 02:08 PM
Sorry if this is a bit of a silly question, but I'm having some trouble getting php inside HTML working on 10.7.2.

The same code inside a .php file works fine. I'm using the version of Apache that ships with OS X and I've uncommented out the php5 module in httpd.conf.

Putting this inside a .html file will not show anything in a web browser.


echo "Testing 1, 2, 3";


Any ideas?

Jan 6, 2012, 02:11 PM
Because this shouldn't be a html file but a php file as there is php code in it.

Jan 6, 2012, 02:16 PM
Just re-read the about.com page on it - epic fail on my part :( Thanks.