Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > XML,XSD,XSLT -> HTML

Reply
Thread Tools

XML,XSD,XSLT -> HTML

 
 
Lars Both
Guest
Posts: n/a
 
      02-17-2005
Hi everybody,

i want to do the following. I have data in a XML-File.
Additionaly I have a XML Schema which defines valid values for every field
and alternative options.
Now I want to create a Stylesheet (for xalan for example) that creates
HTML respecting the actual valus in the XML file and the default data in
the Schema.

An example. The field 'color' has the alternatives red,green and blue
(defined in the XSD). The user already choose green in an earlier session.
This is stored in the XML-File. Now the HTML should offer the user a
select-field with the three options, and 'green' preselected.

Any ideas?
Is my approach right? Maybe there is another way to do something similar.
I am not commited to have 2 files (XSD and XSLT). If there is a way to do
the same thing with one file, thats great to!

Any help is appreciated.

Lars
 
Reply With Quote
 
 
 
 
Martin Honnen
Guest
Posts: n/a
 
      02-17-2005


Lars Both wrote:


> i want to do the following. I have data in a XML-File.
> Additionaly I have a XML Schema which defines valid values for every
> field and alternative options.
> Now I want to create a Stylesheet (for xalan for example) that creates
> HTML respecting the actual valus in the XML file and the default data
> in the Schema.
>
> An example. The field 'color' has the alternatives red,green and blue
> (defined in the XSD). The user already choose green in an earlier
> session. This is stored in the XML-File. Now the HTML should offer the
> user a select-field with the three options, and 'green' preselected.
>
> Any ideas?


XSLT 2.0 and XPath 2.0 have (optional) XSD schema support, Saxon is
already available as an implementation trying keep up with the XSLT
2.0/XPath 2.0 (and even XQuery 1.0) specifications while they reach the
final status. However the schema aware version of Saxon is a commercial
product, check <http://www.saxonica.com/> for details.

With XSLT/XPath 1.0 all you can do is write your own stylesheet
templates extracting for instance the enumerated values from the schema.


--

Martin Honnen
http://JavaScript.FAQTs.com/
 
Reply With Quote
 
 
 
Reply

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
firefox html, my downloaded html and firebug html different? Adam Akhtar Ruby 9 08-16-2008 07:55 PM
How do I identify word<html><html>other word? Laura Perl 1 06-04-2004 11:32 PM
how to redirect to a frames-based html page and load the right html when coming from an ASP.NET page Mark Kamoski ASP .Net 2 08-13-2003 05:51 AM
how to redirect to a frames-based html page and load the right html when coming from an ASP.NET page Mark Kamoski ASP .Net 1 08-13-2003 05:51 AM
How to use HTML::Parser to remove HTML tags and print result Mitchua Perl 1 07-15-2003 02:02 PM



Advertisments