On Wed, 06 Jun 2001 16:44:41 -0500 Ian Bicking <[EMAIL PROTECTED]> wrote:
>[EMAIL PROTECTED] wrote:
>> Enhydra's XMLC is designed to be editable in WYSIWYG composition tools. Or
>> so it is claimed.
>
>For the collective knowledge, after reading xmlc.enhydra.org a little:
>XMLC semantically seems to be similar to some of the simple templates
>systems that were passed around -- basically, you can just mark blocks
>in XMLC. This is done with the id attribute... i.e., to mark a block
>you use:
>
><span id="blockname">some text, maybe which will be replaced</span>
It's this part which supposedly makes it so compatible with WYSIWYG HTML
editors.
>Otherwise XMLC is entirely code-driven. It basically parses the
>HTML/XML document, and presents the Java programmer with a the
>standard DOM for the document, which they can manipulate to create the
>dynamic page. ID tags make it easier to find particular elements, and
>thus give a way to mark text. But marking things is *all* you can do
>when editing HTML.
Yes, things like element collections are not supported that well, or weren't
when I last checked, meaning that generation of collections in the output
document needs to be done programmatically. This is one area where DTML is
quite useful, in my opinion, with its 'dtml-in' element.
>I imagine there's useful functions to manipulate the document in
>typical ways. But the basic concept is very minimal, far more than
>ZPT, and more minimal than nearly all the systems presented here.
>However, ID tags are probably better supported than ZPT's extended
>attributes.
Yes. It's the thinking that has gone into making it compatible with WYSIWYG
editors that makes XMLC stand out from "yet another template syntax".
>I think extended tags have shown themselves to be very difficult to
>use. DTML-style tags produce wildly improper HTML, not to mention XML
>(e.g., <img src="<dtml-var imagename>">). They also are unfriendly to
Well, this isn't valid XML, to my knowledge, but I wasn't talking
about "extended HTML" syntax; I was talking about XML. Anyway, DTML offers a
selection of entities for this case, doesn't it?
>nearly all HTML-based tools, which is ironic in a way. XSL-style
>declarations seem like they make something simple into something very
>very hard. So I'm not sure what an XML form of template declaration
>should be. ZPT feels like the best example of an XML-based template
>language I've seen so far.
I haven't really used XSL, but one of the things which doesn't seem apparent to
me is how one can tailor the appearance of the final output without having to
transform XML documents to HTML documents (for example) on a repeated, trial-
and-error basis to see whether the "stylesheet" is right.
>Also, these all make it hard to generate non-XML/HTML forms of text,
>which includes CSS -- which is very important to XML -- and
>JavaScript. Using XML with quoted text (e.g., <img src="<var
>name="imagename">">) is possible, but also horribly ugly.
Amusingly, I think my Web mailer managed to convert the entities you used in
that example, but I see what you mean; see my XForms work for an example of
that:
http://www.paul.boddie.net/Python/XForms.html
>If you have other examples of XML syntaxes, please tell -- I always
>like novelty.
My newer XMLForms work uses XML namespaces instead. Here's a "group" definition
from the example:
"""
<group name="modules">
<content>
<xhtml:tr>
<xhtml:th>Module name:</xhtml:th>
<xhtml:td>
<string name="name" required="1" min="1">
<content/>
</string>
</xhtml:td>
<xhtml:th>
<boolean name="module_selected">
<content/>
</boolean>
</xhtml:th>
</xhtml:tr>
<xhtml:tr>
<xhtml:th>Document URL:</xhtml:th>
<xhtml:td xhtml:colspan="2">
<string name="document_url">
<content/>
</string>
</xhtml:td>
</xhtml:tr>
</content>
</group>
"""
See: http://www.paul.boddie.net/Python/XMLForms/index.html
A group (nomenclature taken from earlier XForms documentation) is a level in
the hierarchy of elements in a data model (description). Each element in
the "modules" collection at an appropriate point in the actual data hierarchy
is mapped to the content in the above group, producing two XHTML table rows in
this case. Inside each element, the "name", "module_selected"
and "document_url" values are taken and placed into the generated XHTML,
usually inside XHTML 'input' elements - this is defined by various "format"
handlers.
Given that two separate namespaces are used, the only "extended syntax" is the
legitimate invention of new elements for the purposes of XMLForms, and this is
confined to the XMLForms namespace (the default namespace in the above
example). I would think that a good XML editor would be able to treat one
namespace as "structure" and the other (XHTML) namespace visually, but I
suppose that The Devil's Winter Collection will be revealed to the fashion
press before this ever happens.
Regards,
Paul
--
Get your firstname@lastname email for FREE at http://Nameplanet.com/?su
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/webware-discuss