I have some .htm files I want to parse as PHP, but I can't find any resources for this. I tried adding the following to my configuration file, but got some strange results (described below):
[code]
# process html files as php
location ~* .(htm|html)$
{
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include /usr/local/nginx/conf/fastcgi_params;
fastcgi_param SCRIPT_FILENAME /home/public_html/my_real_domain.com/public/$fastcgi_script_name;
}
[/code]
For new files containing php, it parsed them just fine. So I know this works.
But for existing files in which I modified any of the php or html markup, the server would dish up the old version of the file. I ran some tests, checking the source on the server and the files had been updated. I changed some html elements and did a view source on the client and confirmed the old files were being served. I also checked from a clean machine to ensure it wasn't a browser caching issue.
Any ideas how to solve this?
Thanks!