[REBOL] [UPDATE] standard-message-function-library.r
From: rchristiansen::pop::isdfa::sei-it::com at: 5-Jan-2001 18:51
The XML-based Standard Message dialect page has been updated here...
http://www.dangeroustechnology.com/
The Standard Message Function Library file has been renamed and can be
viewed here...
http://www.dangeroustechnology.com/standard-message-function-library.txt
The routines and subroutines I outlined for the system have been updated
with finished subroutines marked in red here...
http://www.dangeroustechnology.com/#one2
Here is a quick overview of usage for the Standard Message Function Library
in its current state:
USAGE:
Messages can be translated from the REBOL object! datatype to the XML-
based Standard Message (and vice-versa) using a translator.
To translate from object! to XML:
translate-message/markup-data rebol-object
To translate from XML to object!:
translate-message/read-markup %filename
Messages can be translated from cgi input, an e-mail message or a
newsgroup message to the REBOL object! datatype using a translator. The
data must first be retrieved using REBOL's built-in Internet protocols, which
places the data into a cgi object! or e-mail object!
To translate from cgi input to the standard message object!:
decode-to-object/from-cgi cgi-object
To translate from e-mail or newsgroup messages
to the standard message object!:
decode-to-object/from-email email-object
XML files are named based on the time they are generated.
To generate a file name based on time:
time-in-digits now
Messages are created using CGI on a web server.
To decode CGI input from the web server:
cgi-input: retrieve-user-data
Write the XML-formatted standard message data with
a file name determined by messageID and to a directory
determined by messageType.
write-xml-message xml-message-string
Messages are requested using CGI on a web server.
Read a directory of file names corresponding to
a directory of XML-formatted standard messages
with the directory determined by messageType.
read-message-directory message-request-data
Read a specific XML-formatted standard message
with the directory determined by messageType
and the file name determined by messageID.
read-message message-request-data
Read a directory of XML-formatted standard messages
with the directory determined by messageType.
read-directory-messages message-directory message-request-data
Messages are displayed as text/html output to a browser.
Markup a standard message using standardized
cascading style sheets tags as the display markup.
display-markup/css xml-message-string
Markup a standard message using a set of HTML tags
as defined in an external object! as the display markup.
display-markup/html xml-message-string html-tags