문제

I need to define a custom type date with some restriction. Currently i have:

<xs:simpleType name="validdatetype">
  <xs:restriction base="xs:date"/>
    <xs:minInclusive value="1900-01-01"/>
  </xs:restriction>
</xs:simpleType>

But when i try to open with some browser i get:

"Opening and ending tag mismatch: simpleType line 0 and restriction"

What am i doing wrong and how can i solve this? Thanks in advance and excuse my poor english!

도움이 되었습니까?

해결책

Your xs:restriction element is closed twice. Here's a fix:

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:simpleType name="validdatetype">
    <xs:restriction base="xs:date">
      <xs:minInclusive value="1900-01-01"/>
    </xs:restriction>
  </xs:simpleType>
</xs:schema>
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top