[XML-SIG] Useless fun thing for XML - comments or helpers?
Fredrik Lundh
fredrik@pythonware.com
Thu, 3 Sep 1998 16:44:56 +0100
><!-- DTD for XBEL - XML Bookmark Exchange Language -->
>
><!ELEMENT XBEL (INFO, NODE+)>
><!ELEMENT NODE (NAME, BOOKMARK+)>
>
><!ELEMENT BOOKMARK (NAME, URL)>
>
><!ELEMENT INFO (OWNER, MACHINE, VERSION, DATE?)>
>
><!ELEMENT OWNER (#PCDATA)>
><!ELEMENT MACHINE (#PCDATA)>
><!ELEMENT VERSION (#PCDATA)>
><!ELEMENT DATE (#PCDATA)>
>
><!ELEMENT NAME (#PCDATA)>
><!ELEMENT URL (#PCDATA)>
Note that nodes can contain other nodes (bookmarks and nodes are
mixed in the order they are found), and the top node doesn't have
a name element. Let's see... Is the following valid syntax?
<!ELEMENT NODE (NAME?, (BOOKMARK|NODE)+)>
I'm not that happy about the name "node" either... anyone have a
better idea?
...
And yes, MSIE also uses a timestamp for each bookmark:
[InternetShortcut]
URL=http://www.secretlabs.com/
Modified=107CD6B43F8ABD019D
(haven't figured out how to decipher that one yet)
Netscape uses at least three: ADD_DATE, LAST_VISIT, and
LAST_MODIFIED (standard time_t's).
How about:
<!ELEMENT BOOKMARK (NAME, URL, ADDED?, VISITED?, MODIFIED?)>
(where dates are stored according to http://www.w3.org/TR/NOTE-datetime
or RFC1766 or something -- is there a "defacto standard" for dates in XML?)
Cheers /F
fredrik@pythonware.com
http://www.pythonware.com