Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
278 views
in Technique[技术] by (71.8m points)

Parsing HTML files as PHP

Is this the correct way to parse html files as php?

RemoveHandler .html .htm
AddType application/x-httpd-php .php .htm .html

Saved in a .htaccess file in my root folder?

I am adding in a navigation bar that is called in via php and this would save renaming all my html files!

Thanks

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
RewriteEngine on 
RewriteRule ^(.*).htm $1.php

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...