xdg Digest, Vol 16, Issue 34

Timo Stülten timo at stuelten.de
Wed Jul 27 02:36:12 EEST 2005


> On 7/25/05, Christopher James Lahey <clahey at ximian.com> wrote:
> > Does anyone have any suggestions for how to proceed here?  I want to
> > make the mime system detect docbook, since there is a mime type for it.

> > > Alternatively, is it possible to specify an empty namespace and just
> > > specify the localname?  That way any xml docs that match as <article>
> > > or <book> would just be labeled as docbook.
A lot of docbook files on my system only have <chapter>s in them. They do not 
have a DOCTYPE, nor any URI. 
Without a proper DOCTYPE/URI, there is no clean way to recognize them by 
content as <article> and <chapter> are not very specific to docbook I think. 
May be it's better to simply use a unique file extension (=".docbook")? All 
chapter-files on my system here already end in ".docbook".

> > > ----- Forwarded message from Christopher James Lahey
> > > <clahey at ximian.com> -----
> > > can be identified by namespace and root element name, but docbook
> > > appears to not use a namespace.  Could this be extended to include
> > > checking the uri of the doctype?  Perhaps alternatively we could check
> > > the pubid of the external entity of the doctype?
Recognizing DOCTYPE in addition to namespaces may fix problems with a lot of 
files. Magics/Matches should suffice for most cases already. Or is there a 
need to differ between some magic and a DOCTYPE or an URI?

-Timo-

-- 
------------------------------------------------------------------------
Timo Stuelten                                        t.stuelten at tu-bs.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/xdg/attachments/20050727/672abf23/attachment.pgp 


More information about the xdg mailing list