Please Login or Register

Server Side Includes (SSI)

How do I use .html files to run php or SSI (Server Side Includes)?

Your Apache Handlers section in cPanel is what you would use to specify how to treat file types. By default, html will not run server side includes or php. To allow these you need to add a new handler for HTML:

To allow php set 'html' as 'application/x-httpd-php'
To allow ssi set 'html' as 'server-parsed'

This will tell the server to read the html files so that you may use these directives in them. Then, in your .html file, add this line:



Was this answer helpful?

Add to Favourites Add to Favourites

Print this Article Print this Article

Also Read
.htaccess Tutorial (Views: 8968)

awards_sum