How to validate a xml file by an external dtd file?

Discussion in 'XML' started by yw, Aug 1, 2005.

  1. yw

    yw Guest

    Hi,
    I use xerces to parse a xml file, but I don't know how to validate the xml
    file with an external dtd file, anyone can help me?

    or whether there are some other methods to do this?

    Thanks
     
    yw, Aug 1, 2005
    #1
    1. Advertising

  2. yw <> wrote:

    > Hi,
    > I use xerces to parse a xml file, but I don't know how to validate
    > the xml file with an external dtd file, anyone can help me?


    <!DOCTYPE root SYSTEM "path/to/external/subset">

    with "root" being your root element.

    --
    David Håsäther
     
    David Håsäther, Aug 1, 2005
    #2
    1. Advertising

  3. yw

    yw Guest

    Thanks for your answer, I am a novice at XML, can your explain the method
    more detailed? and some demo code is better, thank you very much.



    "David Håsäther" <> wrote in message
    news:Xns96A56721A397Edavidhasather@195.67.237.53...
    > yw <> wrote:
    >
    > > Hi,
    > > I use xerces to parse a xml file, but I don't know how to validate
    > > the xml file with an external dtd file, anyone can help me?

    >
    > <!DOCTYPE root SYSTEM "path/to/external/subset">
    >
    > with "root" being your root element.
    >
    > --
    > David Håsäther
     
    yw, Aug 2, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. John_Woo
    Replies:
    4
    Views:
    682
    John_Woo
    Jan 24, 2006
  2. Duane Morin
    Replies:
    1
    Views:
    923
    Patrick TJ McPhee
    Dec 11, 2003
  3. Georg J. Stach
    Replies:
    7
    Views:
    8,054
    JAPISoft
    Sep 26, 2005
  4. Replies:
    0
    Views:
    1,367
  5. test
    Replies:
    2
    Views:
    2,194
    Oliver Wong
    Jul 28, 2006
Loading...

Share This Page