Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > Length Limit on XHTML type in a schema document.

Thread Tools

Length Limit on XHTML type in a schema document.

Binesh Bannerjee
Posts: n/a
I've asked before about making an element in a schema be
able to use xhtml... I've attached my schema definition below...

What I'm curious about, is whether there's a means to add a length
restriction to the memo field in there... I want to restrict it
to say 200 bytes, including tags and all... Is that possible?
Something like the way I can do this for a string field?
<xsd:simpleType name="fifteen">
<xsd:restriction base="xsd:string">
<xsd:maxLength value="15"/>

Thanks! My schema definition follows.

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlnss="" xmlnshtml="" version="1.0">
<xs:import namespace="" schemaLocation="xhtml1-strict.xsd" />
<xs:element name="person">
<xs:element name="name">
<xs:element name="first" type="xs:string" />
<xs:element name="last" type="xs:string" />
<xs:element name="memo" type="xhtml:Block" />

"Danger. Ha. I laugh in the face of Danger - then hide until it
goes away." -- Xander, Buffy the Vampire Slayer

PGP Key:
PGP Key fingerprint = 421D B4C2 2E96 B8EE 7190 A0CF B42F E71C 7FC3 AD96

SSH2 Key:
OpenSSH Key:
BubbleBabble = xibeb-voges-havez-pabaf-debop-cylil-lelyc-viruv-bygeg-zotoh-dixex
Fingerprint = 9d:7c:84:5d:80:e3:65:8d:ee:9e:a3:b9:56:0a:e9:ad

SSH1 Key:

CipherKnight Seals:
Decrypt with CipherSaber2 N=256, Password="WelcomeJedi!" (No quotes)

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
PSD to XHTML Conversion, PSD to HTML, Joomla, Drupal, WordpressConversion, PSD to XHTML CSS xhtml champs C Programming 0 08-01-2011 06:29 AM
convert xhtml to another xhtml using xslt Usha2009 XML 0 12-20-2009 01:13 PM
Should I Convert Site To XHTML or XHTML mobile? chronos3d HTML 9 12-05-2006 04:46 PM
parse URL (href) from xhtml, xhtml -> text, for data XML 7 02-08-2006 07:39 PM
[XML Schema] Including a schema document with absent target namespace to a schema with specified target namespace Stanimir Stamenkov XML 3 04-25-2005 09:59 AM