Methods and systems of authoring XML using DHTML views and XSLT are
described. Various user interfaces can be automatically or
semi-automatically provided in a DHTML view that enable a user to
interact with the DHTML view. The interfaces, some of which are termed
"in document" interfaces, permit a user to interact with a DHTML view and
have those interactions automatically made to a corresponding XML
document that describes data that is associated with the DHTML view.
Presentation of the various in document interfaces takes place by
considering not only an XML schema (of which the XML document is an
instance), but an XSL-T (XSLT transformation) that was utilized to
transform the XML document into the DHTML view. In addition, the notion
of a crystal is introduced and is used to map interactions with a DHTML
view directly back to a corresponding XML document. A crystal, in a basic
form, includes one or more behaviors and associated XSL-T. The crystals
are used to transform XML into the DHTML views. The behaviors of a
crystal are defined to be data-shape specific or dependent, with the data
shape being defined by the XML document. The behavior is not necessarily
dependent upon any schema, data or tags. Because of its data-shape
dependent nature, crystals can be packaged for reuse with various XML
documents which have no relation to one another other than a shape that
is defined by the XML. Behaviors can be attached to DHTML tags that are
generated by the XSL-T. The behaviors ensure that user interactions with
the DHTML view are mapped directly back to the XML document. In this way,
the XML document can be authored to reflect the changes that are made to
the DHTML view by the user.