How do I incorporate my php elements into the template since it ends in .html?? How do I incorporate my php elements into the template since it ends in .html??
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

How do I incorporate my php elements into the template since it ends in .html??

Started by aka1908, September 20, 2004, 06:52:09 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

aka1908

How do I incorporate my php elements into the template since it ends in .html?  I want to add php elements to my gallery, but the template ends in .html therefore my php includes do not work.  How do I change that?

Thanks in advance!

Tranz

Have you done a search? This question has been asked many times before.


Joachim Müller

If your search hasn't come up with proper results, you should have re-phrased your search keywords - the answer has been given before, as TranzNDance suggested.

If it's a plain html page (which means it's static), you can't have dynamic content from Coppermine in it (exclamation mark). If the extension of the file is just named ".htm", but the server it is on allows you to have php files, you could
a) rename the html file to php (recommended)
or
b) use this method (if you're on apache and your webhost let's you use .htaccess): Create a file called ".htaccess" (mind the dot at the start) if it doesn't already exist in the folder your html file is in. Add this line of code to it:<FilesMatch "\.(htm)$" >
ForceType application/x-httpd-php
</FilesMatch>
This lines will instruct the server to parse files with the extension ".htm" with the php parser.

You can then use the random image include mod or the rss feed mod from the mods board.

Joachim