The functionality of the web page editor is available within certain applets of the administration tools and can be used to edit HTML, RSS and RDF documents by using a Wiki-like text-based syntax. A special instance of the web page editor is also used to edit the bookmarks page (see also section "Built-in Help System").
Full support for WML pages may follow in a future release, currently, only the conversion of all cards that are contained in a WML deck (the whole document) to an HTML page is available, which by itself may already be rather helpful. The tokenized (binary) form of WML is also recognized.
The web page editor is part of the applets EditPage and Filesys, which are briefly described in the following subsections.
The applet EditPage operates much the same way as the
applet Filescan does, which treats the whole local
filesystem as a website. In doing so, files are served as usual (like a
web-server) and directory listings are generated for directories that do no
provide an index file instead. This applet can be accessed by using
the internal URL
When a file with a content-type that can be handled by the web page editor is recognized, the contained document is first converted to HTML if it is not already HTML, in order to afterwards add certain hyperlinks at the end of the returned page. These hyperlinks allow a user to edit the document, to view its textual representation that is also used for editing, or to get the original document.
Editing of a document is performed with the help of an HTML page that provides a formular and certain additional information about the document in question. The formular consists of a textarea input element and two submit buttons, one for saving the modified document and the other for getting a preview of it. The textarea input element contains a textual representation of the document that is going to be edited. By saving the document, the (submitted) textual representation is converted back again to the target format of the document and the result is finally saved to the file.
The applet Filesys allows to perform many administrative
tasks on files and directories of the local filesystem and makes it also
possible to create and edit text-based files. This applet can be accessed by
using the internal URL
For each file in a directory listing that is generated by this applet, two additional hyperlinks that allow to edit a file either directly as plain text (T) or by using its textual representation (E) are provided. A selection list element together with a submit button allows to create different types of files and is provided at the bottom of a directory listing.
Editing of a document is performed with the help of an HTML page that provides a formular. The formular consists of a text input element for the filename, some selection list elements for the filetype, the charset and the line separator, a textarea input element and a submit button for saving the document. The textarea input element contains a textual representation of the document that is going to be edited. By saving the document, the (submitted) textual representation is converted to the specified format of the document and the result is finally saved to the given file.
It should be noted that the web page editor always works directly on the source documents. The textual representation is only used as an intermediate format for editing and is not stored anywhere. Instead, it is generated on-the-fly from the current source document and is finally converted back again to the target format. This way it is very easy to import documents, edit them with the editor and finally export them again for further processing, if one or the other action is necessary at all.
All documents that are produced by the web page editor are fully compliant to XML (see also [XML]). In order to guarantee best interoperability of the generated documents, all characters outside the US-ASCII range are always encoded as numeric entity references using a decimal representation, so that any character encoding (charset) that includes the US-ASCII range as a subset can be applied to such a document.
The main reason of editing the textual representation of a document rather than the source document itself rests on the assumption that it is easier to understand and work with such a text format, primarily because a user is not required to have in-depth knowledge of the underlying document format, although a certain understanding may be helpful.
The structure (layout) of a textual representation is more or less based on the visual appearance of a document as it would be displayed by a text-based browser or similar application, but certain additional hints and directives that are usually not displayed by such a browser may be present in order to resolve ambiguities or to assign special meanings to pieces of text. For example, an indented block of text without further information represents a three-fold ambiguity in case of HTML: It can be interpreted either as preformatted text, as an indented paragraph, or as a block quotation. And special meanings are also needed for HTML in order to identify hyperlinks and emphasis.
The format of textual representations for all document types that are recognized by the web page editor are described in detail in the following sections: