Gossamer Forum
Home : Products : Gossamer Forum : Discussion :

Advanced Template Editor?? - Template Update Chore

Quote Reply
Advanced Template Editor?? - Template Update Chore
Wow... trying to upgrade templates is a real chore!

What is badly needed is a better diff editor for the templates. The diff function is pretty cool, but extremely limited. With ths nice job you did with the editor, a similar "Advanced Template Editor" would be so slick.

I've got a pretty good diff tool that highlights alterations between two files - but it is stand-alone and requires the files to be in a directory.

Is there an easy method to dump all the templates (altered and original) to two directories?

-jh
Quote Reply
Re: [oog] Advanced Template Editor?? - Template Update Chore In reply to
>>I've got a pretty good diff tool that highlights alterations between two files - but it is stand-alone and requires the files to be in a directory. <<

You mean CS-Diff Wink

>>The diff function is pretty cool, but extremely limited.<<

I think its quite powerful. It would be easier for GT to use CSDiff and publish the output on the web for everyone to see all changes.

Like:

http://213.106.15.150/report.htm

It would be really tricky doing it in perl during upgrades.

Last edited by:

Paul: Apr 8, 2002, 3:53 PM
Quote Reply
Re: [Paul] Advanced Template Editor?? - Template Update Chore In reply to
use a text editor like BBEdit. Laugh

I can use any directory on my computer with having to move any files, let's you know what's new/different/same ... different files just click on the window and it shows you scrollable snippets ....

pretty handy Laugh that's how I found the 50+ different templates between 1.1.1 and 1.1.3 Laugh

openoffice + gimp + sketch ... Smile
Quote Reply
Re: [QooQ] Advanced Template Editor?? - Template Update Chore In reply to
OK... I see there are a few ways to edit. I guess I need to get the raw files. Where exactly is the original and altered template data stored?
Quote Reply
Re: [oog] Advanced Template Editor?? - Template Update Chore In reply to
top end files that most folks see are at:
cgi-bin/gforum/admin/templates/default
- these are the main standard templates.

if you edit through the editor file would be placed in:
cgi-bin/gforum/admin/templates/default/local

I'm pretty sure you can make changes to the templates on your own machine and then up-load them to the "local" directory. Or if you crazy enough and don't want the ability to check for diff (differences) and changes through the various up-grades just dump all your edited templates in the "default" dirctory.

of course there are other directories that have templates in them too like:
admin
common
default
default_top
search_engine

hmmm... no real need to fiddle with the admin ones.

openoffice + gimp + sketch ... Smile
Quote Reply
Re: [QooQ] Advanced Template Editor?? - Template Update Chore In reply to
In Reply To:
Or if you crazy enough and don't want the ability to check for diff (differences) and changes through the various up-grades just dump all your edited templates in the "default" dirctory.
not to mention when you upgrade, your templates are likely to be overwritten... so put your changed templates into the local directory!

Adrian
Quote Reply
Re: [brewt] Advanced Template Editor?? - Template Update Chore In reply to
ahhh gobbers, forgot one of the most important points!
thanks Adrian!

anybody care to explain the details for these 2 sets of templates?

common -- seems to be the main java code depository
default_top -- seems like a repeat of default ... but what's the difference?

openoffice + gimp + sketch ... Smile
Quote Reply
Re: [QooQ] Advanced Template Editor?? - Template Update Chore In reply to
Hi,

The template system supports the concept of "inheritance". Inside each template directory, there is a .tplinfo file that says where to look for if you don't find the requested template.

So for instance, the default template set, says to look in common. That way, the 20 or so templates required for the HTML editor, which rarely need to be altered, can just be stored in common. Now any new template set you make, as long as it inherits from common, you won't need to replicate the html editor.

default_top is an example of making a new template set that only affects a few files. It changes the look of how a post is displayed, so the only template in there is include_post_display.html, the rest are inherited from default.

Let me know if that doesn't make sense.

Cheers,

Alex
--
Gossamer Threads Inc.