By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,401 Members | 793 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,401 IT Pros & Developers. It's quick & easy.

Xml, xsd, xslt and default values in xercesc

P: n/a
Hi All,

I have small problem. We are using xslt to display xml in web browser. But
our (any?) xslt does not support default values stored in xsd ... it leaves
empty holes in table. Therefore I need to write them to xml explicitly. I
would like to load them from xsd. Is it possible in xerces ? I create empty
DOM document and store it to file. Is it possible to bind schema to document
and retrieve default values for attributes before storing to disk ?

Best Regards

Jacek

Mar 14 '06 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Jacek wrote:
our (any?) xslt does not support default values stored in xsd ... it leaves
empty holes in table.


Make sure the parser being used by your XSLT processor is running in
validating mode. If it is, it should be taking care of default values
before XSLT sees the document.

--
Joe Kesselman / Beware the fury of a patient man. -- John Dryden
Mar 14 '06 #2

P: n/a
> Make sure the parser being used by your XSLT processor is running in
validating mode. If it is, it should be taking care of default values
before XSLT sees the document.


Unfortunately we are using web browser ... for example IE :). I don't think
it is possible to force it to read default values from schemas.

Regards
Jacek
Mar 15 '06 #3

P: n/a
Jacek wrote:
Unfortunately we are using web browser ... for example IE :). I don't think
it is possible to force it to read default values from schemas.


In that case, like a young codfish, you're scrod. If the parser doesn't
read the schema or DTD, you don't have the defaults. Preprocess on the
server end to copy the defaults in as explicit values, so you aren't
dependent on them.

--
() ASCII Ribbon Campaign | Joe Kesselman
/\ Stamp out HTML e-mail! | System architexture and kinetic poetry
Mar 16 '06 #4

P: n/a
> In that case, like a young codfish, you're scrod. If the parser doesn't
read the schema or DTD, you don't have the defaults. Preprocess on the
server end to copy the defaults in as explicit values, so you aren't
dependent on them.


Thanks for repeating conclusion from my first post. I was hoping that
someone knows how to do this.
Regards
Jacek
Mar 18 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.