|
||||
[Chameleon] move imagetip into the language dbf files?Paul Spencer spencer@dmsolutions.caSun, 18 Jan 2004 22:05:24 -0500
|
Bart, I am against putting anything from the HTML template into dbf files except *possibly* as default values in the cases like image tip so if no value is defined then one might be looked up in a dbf file for the specific widget. I don't think this would be a bad idea, actually. Another option would be to include the ability to specify language resources in a template and reference them within widgets, for instance: <cwc2 type="SharedResource" name="Language"> <resource id="1"> <text language="en-CA">English Text</text> <text language="fr-CA">French Text</text> <text language="nl-NL">Dutch Text</text> </resource> </cwc2> and then in a widget tag, a reference like <cwc2 type="ZoomIn" ImageTip="#1"/> would replace #1 with the appropriate text. This might be acheivable within the widget parsing code rather than within the widgets themselves, making it compatible with existing widgets and not requiring extensive changes. The #1 syntax would probably not be the final but it might be something like that. In order to make this useful, though, we need your second suggestion and as it turns out there is an undocumented feature that allows this. It will be documented at some point. In the meantime, there are two pre-processor directives in chameleon: 1. includes. Includes are simply an ability to insert another document into the current template prior to parsing for widgets. The syntax is [!filename!] 2. URL replacements. URL replacements are done on URL parameters (case-insensitive) and the syntax is [#variable#]. Both pre-processor commands work anywhere in a template, both in and outside of widget tags. Cheers, Paul Bart van den Eijnden wrote: > Hi list, > > would it be an idea not to have the imagetip attribute in the HTML > template but in the language dbf files? > > I now have 5 applications to maintain, and everytime the customer wants > to have the hint of the buttons changed, I have to change it at 5 > places. Would be nice to have this in a centralized position, and I > personally don't see the need to have it in the HTML template, but > perhaps I am overseeing something? > > Maybe the same could apply to the label attribute of the Cursorpos and > Rulerresult widgets? > > Also, it would be nice to have parts of an HTML template which can be > reused without having to copy them, i.e. linking in HTML template subsets? > > Best regards, > Bart > _______________________________________________ > Chameleon mailing list > Chameleon@lists.maptools.org > http://lists.maptools.org/mailman/listinfo/chameleon > -- ----------------------------------------------------------------- |Paul Spencer spencer@dmsolutions.ca | |-----------------------------------------------------------------| |Applications & Software Development | |DM Solutions Group Inc http://www.dmsolutions.ca/| -----------------------------------------------------------------
This archive was generated by Pipermail. |
MapTools.org -- Hosted by DM Solutions Group |