Next: Miscellaneous, Previous: Objects Classes and Modules, Up: Top [Contents][Index]
Kawa has a number of features for working with XML, HTML, and generated web pages.
In Kawa you don’t write XML or HTML directly. Instead you write expressions that evaluate to “node objects” corresponding to elements, attributes, and text. You then write these node objects using either an XML or HTML format.
Many web-page-generating tools require you to work directly with raw HTML, as for example:
(display "<p>Don't use the <code><blink></code> tag.</p>")
In Kawa you would instead do:
(display (html:p "Don't use the " (html:code "<blink>") " tag."))
The conversion from node objects to XML or HTML is handled by the formatter (or serializer). Some advantages of doing it this way are:
• Formatting XML: | ||
• Creating HTML nodes: | ||
• Creating XML nodes: | ||
• XML literals: | ||
• Server-side scripts: | Writing web-server-side Kawa scripts | |
• Self-configuring page scripts: | ||
• Servlets: | Installing Kawa programs as Servlets | |
• CGI scripts: | Installing Kawa programs as CGI scripts | |
• HTTP requests: | Functions for accessing HTTP requests | |
• HTTP response: | Functions for generating HTTP response | |
• XML beyond Scheme: | Using non-Scheme languages for XML/HTML |
Next: Miscellaneous, Previous: Objects Classes and Modules, Up: Top [Contents][Index]