Pixelpost Forum

Pixelpost Forum (http://www.pixelpost.org/forum/index.php)
-   Template design and Front-End Code (http://www.pixelpost.org/forum/forumdisplay.php?f=20)
-   -   having php template files? (http://www.pixelpost.org/forum/showthread.php?t=9979)

impete82 12-14-2008 07:49 PM

having php template files?
 
i want to use php include so i don't have to change each menu whenever i make one little change, how can i go about using .php instead of .html on my template pages? unless there's a different way of doing this

Dennis 12-15-2008 04:04 PM

PHP is not supported in templates. There is however a way to fix this. Create an addon in PHP that creates a menu.

Include a tag (e.g. <MY_MENU>) in the HTML template files and let the addon replace the tag with the actual HTML code.

HTH.

dakwegmo 12-16-2008 02:33 AM

You can also add header and footer files to the template directory, so that you don't have to repeat the code on every page. Just create header.html and/or footer.html and place them in your template folder. They'll show up at the beginning and ending of each page on your site. Remember to remove the headers from each of your _template files or you'll have duplicate information on each page.

impete82 12-16-2008 02:29 PM

you know, that's what i did after reading it somewhere on the forums after posting this thread :) it's working great (using the header.html & footer.html files) but there are some external scripts i'd like that use php also, for which i guess i'd have to learn how to write a addon hehehe :(

joelpietersen 01-30-2009 05:57 AM

Yeah, that will really work great but I have the same issue with external scripts which I'm also trying to discover right now.


All times are GMT. The time now is 03:14 AM.

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.