How can one differentiate between a PHP file and an HTML file when including PHP code?

When including PHP code in a file, one way to differentiate between a PHP file and an HTML file is by using the file extension. PHP files typically have a .php extension, while HTML files have a .html or .htm extension. By naming your files accordingly, you can easily identify which files contain PHP code and which files contain only HTML code.

// Example of including a PHP file with PHP code
include 'myfile.php';

// Example of including an HTML file without PHP code
include 'myfile.html';