Author Topic: XML puzzler  (Read 154 times)

Offline Wolfala

  • Platinum Member
  • ******
  • Posts: 4875
XML puzzler
« on: October 24, 2007, 01:27:05 AM »
I was given a problem at class tonight that has me stumped. If anyone is good at XML, i'll fed ex ya the alcohol of your choice.

Here is the whole problem, the "body" with "arbitrary markup" is where I might run into problems.

Write an XML schema for this:

    * An element of type note that contains 4 child elements: to, from, subject, body
    * All from, subject, and body are required to occur exactly once.
    * To must occur one or more times
    * The element body may contain arbitrary markup from any XML namespace
    * The elements to, subject, and from may contain only string data
    * The element subject has a required attribute called date with the validated format "mm/dd/yyyy" where mm represents month 1-12, dd represents 1-31, and yyyy represents a 4-digit year

Wolf


the best cure for "wife ack" is to deploy chaff:    $...$$....$....$$$.....$ .....$$$.....$ ....$$

Offline Pei

  • Silver Member
  • ****
  • Posts: 1903
Re: XML puzzler
« Reply #1 on: October 24, 2007, 04:48:00 AM »
Quote
Originally posted by Wolfala

Here is the whole problem, the "body" with "arbitrary markup" is where I might run into problems.


Lookup the schema element "any".