1
retspoox
How do I add a new template to a module template set?
  • 2005/1/11 16:53

  • retspoox

  • Just popping in

  • Posts: 16

  • Since: 2004/3/16


I have searched forums/docs but so far have not found the answer, so maybe some more enlightened soul will illuminate me.
I had been successfully hacking on a module and changing a cloned set of templates to suit my purposes when I needed to add a new template for a new set of functionality.
My first thought was to copy an existing file and modify it. This new file shows up in the template manager with a "generate" button enabled. Locating my new file with brose box and attempting to generate produces a file not found error.
This sent me searching forums/docs which led to the thought of updating the module in question. However, I became concerned that this might actually overwrite the changes that I made to the templates in the database with the originals from the module/template/ directory.
This brings me to my main questions:
- How do I ensure that changes to templates in the database get saved to module files?
- How do I add a new template file to a module?

2
m0nty
Re: How do I add a new template to a module template set?
  • 2005/1/11 17:22

  • m0nty

  • XOOPS is my life!

  • Posts: 3337

  • Since: 2003/10/24


adding a new template to a module altogether, will need to edit the module php files itself, as those templates are called from the module, if u simply add a template, then the module doesn't know u have added 1 as that template is not coded in the module if u get me..

editing a template should be ok, updating will only regenerate the default tewmplates, your cloned set shouldn't be affected unless u regenerate them..

3
retspoox
Re: How do I add a new template to a module template set?
  • 2005/1/11 19:28

  • retspoox

  • Just popping in

  • Posts: 16

  • Since: 2004/3/16


thanks for responding mOnty,
after reading your reply and a little more meditation I found the location in the xoops_version.php for the mondule where its' templates are listed for inclusion/installation. After adding a new entry and updating the module the new template could then be generated from the template manager.

thanks again

Login

Who's Online

254 user(s) are online (140 user(s) are browsing Support Forums)


Members: 0


Guests: 254


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits