How to parse PHP in html files?

Are you looking to make all the .html pages of your websites to run as .php or you are looking to parse the PHP in HTML files? Please add the below line to your .htaccess file.

AddHandler application/x-httpd-lsphp .htm .html

IMP: Ensure that you take the backup of your existing .htaccess file before making any changes to your existing .htaccess file

Related Articles

How to Install and Configure the HAProxy on CentOS?

HAProxy is a very fast and decent tool to achieve high availability, load balancing. It can work...

How to Install Visual Studio Code on CentOS 7?

Visual Studio Code is a Microsoft Product and an open-source cross-platform code editor. It...

How to install Codeignetor centos 7?

Codeignetor is a PHP framework used to build a web application that is used widely by the...

Do You Provide TUN/TAP On VPS Hosting?

Typically, TUN/TAP is used when you want to utilize VPN services from your VPS. Windows VPS...

How to Protect GRUB with Password in Linux ?

GRUB called as Grand Unified Bootloader is a default Boot loader on Unix OS. In a Linux system,...

  • 0 Users Found This Useful

Was this answer helpful?