Author Topic: Insert a new Template in a existing Template Packet  (Read 6331 times)

0 Members and 1 Guest are viewing this topic.

Offline redgob

  • Pre-Newbie
  • Posts: 3
    • View Profile
Insert a new Template in a existing Template Packet
« on: August 04, 2005, 06:06:41 PM »
Hi everybdy,
i am conrently building a new Template Packet out of the default one. I wanna seperate some often used Thing like the Navigationbar in a seperate file like sidebar.html. The normal way to insert a template is to use the { } bracktes but how can i make it working with my own templates?

Thanks for your help

TheOracle

  • Guest
Re: Insert a new Template in a existing Template Packet
« Reply #1 on: August 05, 2005, 03:47:19 AM »
Ahh ! finally one of my fav question has arrived. 8)

*** Solution 1 ***

A good way to do this would be by implementing your javascript codes in your includes/page_header.php then register the initials from an array which could then be used with brackets from your templates from sidebar.html if you wanted too. ;)

Could you post your sidebar javascript codes ?

*** Solution 2 ***

Or simply implement your codes in header.html file.

Offline redgob

  • Pre-Newbie
  • Posts: 3
    • View Profile
Re: Insert a new Template in a existing Template Packet
« Reply #2 on: August 06, 2005, 12:25:47 AM »
Thanks for your help, but i donīt want to insert javascript code to be used with the brackets. Lets say i wanna insert the same table on every page. it would be insane to insert it on every page, i mean if you wanna to shange the table you have to change it on everypage... A good example is the Thumbnail in the default-packet. They seperated it because a thunbnail should look the same on every page, but can i seperate html code from the rest by my own?


TheOracle

  • Guest
Re: Insert a new Template in a existing Template Packet
« Reply #3 on: August 06, 2005, 01:29:17 AM »
Quote

Lets say i wanna insert the same table on every page


You're lucky. I have done this for myself many months ago. It simplifies the load-up by loading the HTML templates since a single file handles the basic table layout as the rest only initials it with brackets. ;)

Quote

but can i seperate html code from the rest by my own?


In this case, absolutely. Althought, it would take some time to post all the codings in here as most modifications has been done from my end regarding this feature.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline redgob

  • Pre-Newbie
  • Posts: 3
    • View Profile
Re: Insert a new Template in a existing Template Packet
« Reply #5 on: August 13, 2005, 01:43:28 PM »
Thanks for your help everyone. In the mean time i copy-pasted it in every file... but i will try your method to create new template-files.