Record and Information Storage – XML and DTD

Lab 1: XML

XML Lab

Using a text editor create a well-formed and successfully validated XML document. The most common text editors you can use for this Lab are Notepad on a PC and TextEdit – set to PlainText under Preferences – on a Mac.

Required Contents

Your XML document should include:

  • At least three comments
  • At least five different* elements containing character data (i.e. textual content)
  • At least five different* elements containing element content
  • At least two different* attributes
  • At least two different* special characters
  • At least two separate/unique records
  • .xml file extension (important!)

Your XML document must successfully validate with no errors for full credit. Validate the syntax of your XML at: https://www.w3schools.com/xml/xml_validator.asp

You will also need to provide a 2-3 sentence description of your XML document as an overview of its design, contents, and intended purpose. So, not only should you ensure the syntax of your XML document is correct (in that it successfully validates) but you should ensure the semantics and design are sound as well in that it stores information in the most logical and structured way. Input this description directly into the XML document using comment out tags (so it’s not recognized text by the validator). Also, include your name within the actual XML document, again, using comment out tags. These comments (name and description) can count toward the 3 required comments as specified in the Lab criteria listed above.

Submit Here

The .xml file created for the requirements of this lab.

—————————-

*NOTE:  “different” in this context means another unique element, attribute, and special character; repetition of the same element, attribute, or special character across the multiple records does not meet the requirement or meaning of “different.” This is a very important point for earning full credit for this Lab Exercise.

 

Lab 2: DTD

DTD Lab

Requirements

Step 1. 

Make a copy of your XML document that you created for the first lab (never overwrite original work!). Using the copy, create a version that contains the valid inline (or internal) DTD based on your XML document contents and structure. (In real life, creating the DTD would likely come first, or before implementing the XML document – as opposed to after – but this is a learning exercise!).

You still want to ensure that your XML document validates – https://www.w3schools.com/xml/xml_validator.asp

But, this time, also make sure your XML validates against or complies with the structure as defined in the DTD. The website at  http://www.xmlvalidation.com/documentation.html will work for this task; however, after each check or change to your document, make sure to do a complete refresh (instead of using “back” button in the browser) before attempting another check or validation. (This web tool seems to store the cache from a session until a new session is created. A refresh will typically create a completely new session.)

Reminder from the XML Lab, your XML document should include:

  • At least three comments
  • At least five different* elements containing character data (i.e. textual content)
  • At least five different* elements containing element content
  • At least two different* attributes
  • At least two different* special characters
  • At least two separate records

Additional requirement:

  • Add at least two different* entitites

Step 2. 

Create an external .dtd version for original XML document, and create another version of the XML document with the external DTD declared it in your existing .xml file.

You can and should perform the above validation step for both syntax and compliance with the DTD, this time using an external DTD. The tool linked above will also allow you to check the contents and structure of the XML document against an external DTD (select the checkbox on the opening page for specifying use of an external DTD; it will walk you through the steps after that and perform the check).

Submit Here

  1. The .xml file with the internal DTD (from Step 1)
  2. The .xml file with external DTD declared (from Step 2)
  3. The .dtd external document (from Step 2)

———————————–

*NOTE:  “different” in this context means another unique element, attribute, and special character; repetition of the same element, attribute, or special character across multiple records does not meet the requirement or meaning of “different.” This is a very important point for earning full credit for this Lab Exercise.

Record and Information Storage

Part 1: Metadata Recap

There are probably over a hundred different metadata schemas (i.e. element sets) in existence and in use by different projects and efforts. These schemas are all intended to help organize the (digital) resources for different academic and/or professional domains. Many metadata schemas are considered to be “domain specific,” as many academic and professional domains consider themselves as having unique information needs (for organizing purposes) in some way. Post an example of your favorite metadata schema (if you can narrow it down to just one!). This will help all of us get a good sense – from all of many different perspectives and interest – of all the schemas out there in the world of digital libraries!

 

Part 2: Markup: XML and DTD

Post ideas and any snippets of code from your lab work as examples. If you have any questions about designing or implementing your XML/DTD, ask them here. This way, we can all chip in to help troubleshoot!

 

Order from us and get better grades. We are the service you have been looking for.