On Sunday, Oct 26, 2003, at 15:34 US/Central, Brian Candler wrote:

[...]
So I don't think what you propose would be any improvement.


I concur. What he was suggesting sounded much like what's already in place to me as well.



I can see the following improvements which could be made:

1. Separate content entirely from layout, using CSS only. [...]

2. Remove all English language text from the templates, and replace with
pointers into a dictionary file. Translators then don't need to touch the
template HTML/XML, only the dictionary. [...]

Not to discourage anyone else from doing work of course... but these are both aims of my newest sqwebmail project. I've compiled a list of features that people (those who responded to my poll anyway) would like to see, and am trying to work on them. These 2 changes in particular are coming up fast on my list, based on time involved and priority given by those who responded to the informal poll. -- Probably 1-2 minor items that are likely to be quicker changes will come first, then these 2 more highly sought after (but slightly more time consuming) items should be next.


I certainly wouldn't object to anyone else chipping in... not in the least(!) ...but if anyone's interested, I'd like for it to be a collaborative project, rather than having 2 (or more) people working on basically the same thing -- independently of each other.


Optionally, step 3 would be to remove all embedded HTML from the C code, and
move it into the templates. This would require a templating engine, which I
personally would model on Ruby's Amrita: the templates might look something
like this


    <tr id="indexrow">
      <td><span id="from"></span></td>
      <td><span id="subject"></span></td>
      <td><span id="date"></span></td>
    </tr>


Hmm... I've wondered about this (removing all code from the C files) myself previously. But I don't think it's practical at this time. That's a *lot* of C code to change. And probably you'd need to rewrite code in a fairly significant way in some cases where the logic would have to be updated to deal with the change. I think this should be held off till a lot of thought can be put into the best way to change it.


Furthermore, I personally don't especially like the idea of using HTML tags as placeholders for other content. It seems nice at first, in that it leaves you with pure HTML for the templates... But then you have to worry about making sure ID names aren't replicated in the document (i.e. "real" tags sharing a namespace with "replacement" tags), recognizing which tags are "replacement" tags and which aren't when you come back to change templates later, writing your template parser to even just recognize the difference between "your" tags with ID's and "its" tags... and probably a lot of other issues.

Trust me -- I've done that before. The Content Management System we used while I was with SI.com was based on a very similar idea... and it was completely out of control from a management standpoint. The templates were a nightmare to update and keep cleanly coded.

(They've since moved on to a new system, btw. But the system that was in place when I started work there is not something I look forward to seeing again. =)

Nonetheless, with a good design, I much admit it would be nice to not have to touch any C code at all when making changes to the HTML output of sqwebmail. -- But with #1 and #2 being taken care of (relatively soon, hopefully)... I think it will not be as much of a problem, since most of what's embedded in the C code is in fact relatively well written (and CSS-ready) already.

Well, anyway... That's just my 2 cents worth.

-jab




Reply via email to