I have a HTML file that contains this code
<head></head>
<body class="page_bg">
Hello, today is <?php echo date('l, F jS, Y'); ?>.
</body>
</html>
and I am wondering why when I run it only says "Hello today i"
. Without the date. After some research I saw I had to add a .htaccess file with the code AddType application/x-httpd-php .html
inside, yet it still only writes "Hello today is ."
did I save the .htaccess filethe wrong place or is it something else?
I saved it in in a folder called PHP and HTML test
the HTML file and the .htaccess file are both in the same place. I installed PHP with XAMPP.