[horde] Modifying files -- best practice?

Michael M Slusarz slusarz at horde.org
Wed Aug 27 06:42:50 UTC 2014


Quoting Tim Streit <ledoktre at meanie.us>:

> I'm just going through and doing some themeing, and I'm wondering  
> what is best practice to customize some files.
>
> -Themes -- no prob.  Create a new theme.
> -Templates -- ??   For example, most files are using PNG files, I'd  
> rather use SVG - personal preference.  I can modify some files to  
> use this, but I assume next update will undo my work.

Templates (i.e. the View in MVC) are, in general, are a difficult  
thing to abstract. You are correct that you need to make sure to make  
backup copies of your templates when/if you upgrade.

> -/imp/lib/Flag/Imap# vim Deleted.php  -  this is an example of  
> something small-- I want to change the color of an email marked as  
> deleted.

You are correct - this is the only place to change this.  Probably  
need to abstract this better in the future with something like a CSS  
class name ... although part of me says the reason I did it this way  
is because it was not easy to do this via CSS.  (Not looking at the  
code at the moment, so can't provide more insight than that.)

For the record - if doing many changes in Horde, it is probably easier  
to use git instead of installing via packages.  Git will typically  
handle most merges/updates without conflict, so it provides a way of  
using the base files without having to make copies.

> I know on config files, we insert '.local' into the name and put the  
> changes there, and it works.  Is this the same for ALL php files?

No.  This is not a general PHP thing - it is a Horde config file thing.

michael

___________________________________
Michael Slusarz [slusarz at horde.org]



More information about the horde mailing list