Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Senior Coder
    Join Date
    Jun 2002
    Location
    near Oswestry
    Posts
    4,508
    Thanks
    0
    Thanked 0 Times in 0 Posts

    how do I use a PUBLIC DTD?

    I'm publishing something where users will edit an XML document but shouldn't be able to edit the DTD. I was thinking something like:

    <!DOCTYPE udm PUBLIC "http://www.domain.com/my_dtd.dtd">

    would do it, but it seems not to.

  • #2
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,460
    Thanks
    1
    Thanked 23 Times in 21 Posts
    That would work if the keyword was SYSTEM.

    Doctype declaration tags work like this:

    <!DOCTYPE rootElementName PUBLIC "-//human-readable-string//" "http://dtd-location.org/filename.dtd">

    Or:

    <!DOCTYPE rootElementName SYSTEM "http://dtd-location.org/filename.dtd">

    The idea behind the PUBLIC keyword is to include an optional string which describes the language the DTD defines.
    Last edited by Alex Vincent; 12-31-2002 at 12:17 AM.
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #3
    Senior Coder
    Join Date
    Jun 2002
    Location
    near Oswestry
    Posts
    4,508
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I see. Thanks, that's very helpful


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •