XML Editor
Sign up for a WebBoard account Sign Up Keyword Search Search More Options... Options
Chat Rooms Chat Help Help News News Log in to WebBoard Log in Not Logged in
Show tree view Topic
Topic Page 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Go to previous topicPrev TopicGo to next topicNext Topic
Postnext
marcel hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marcel hijma
Date: 02 Mar 2006 09:45 AM
Originally Posted: 02 Mar 2006 06:57 AM
Hello I am trying Stylus. Just as in the video i want to create a XML file from a Webservice. But i am missing the function: XMLTOHTML (like it was showed in the demo) Where is it ?<br> <br> Is there a simple way to get that Webservice (XML) data into a usable XML file ? Like a copy function or so ? SOmehow i can't find this..<br> <br> Thanks ..<br>

Postnext
Minollo I.Subject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: Minollo I.
Date: 02 Mar 2006 09:18 AM
Marcel,
if I well understand what you mean, you are trying to convert a Web Service SOAP response into HTML?

What the video shows (I think) is the XML-to-HTML XSLT WYSIWYG component; we have several videos showing how that works; XML-to-HTML is a "tab" in the XSLT editor. After you have chosen the XML source you want to work with (the web service invocation in this case), you can create your HTML visually drag&dropping dynamic values/tables/lists from the XML source.

Is that what you are looking for?
Minollo

Postnext
marcel hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marcel hijma
Date: 02 Mar 2006 10:32 AM
Originally Posted: 02 Mar 2006 09:53 AM
Hello Minello.<br> Yes that is what i am looking for ..<br> <br> I just made a sample Webservice call and yes it is working nice in Stylus, but now i want to use it in real, so for exmple make a HTML file of it.<br> <br> OK so via XSLT WYS... I can preview the stuff.<br> <br> But the XSL results show this:<br> <br> End of the file:<br> </xsl:template><br> </xsl:stylesheet><br> - <!-- <br> Stylus Studio meta-information - (c) 2004-2005. Progress Software Corporation. All rights reserved.<br> <metaInformation><br> <scenarios ><scenario default="yes" name="uuu" userelativepaths="yes" externalpreview="no" url="ws:///ok.wscc" htmlbaseurl="" outputurl="" processortype="internal" useresolver="yes" profilemode="0" profiledepth="" profilelength="" urlprofilexml="" commandline="" additionalpath="" additionalclasspath="" postprocessortype="none" postprocesscommandline="" postprocessadditionalpath="" postprocessgeneratedext="" validateoutput="no" validator="internal" customvalidator=""/></scenarios><MapperMetaTag><MapperInfo srcSchemaPathIsRelative="yes" srcSchemaInterpretAsXML="no" destSchemaPath="" destSchemaRoot="" destSchemaPathIsRelative="yes" destSchemaInterpretAsXML="no"/><MapperBlockPosition></MapperBlockPosition><TemplateContext></TemplateContext><MapperFilter side="source"></MapperFilter></MapperMetaTag><br> </metaInformation><br> <br> <br> --> So the preview show the right data, but the output file not ...

Postnext
Minollo I.Subject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: Minollo I.
Date: 02 Mar 2006 10:12 AM
Marcel,
the goal of the XML-to-HTML WYSIWYG component is to generate an XSLT that, when applied to the XML source you specify, generates the HTML output you have designed.

So, if you design and preview the HTML in the WYSIWYG tab, and then you switch back to the source tab (or if you open the generated XSLT manually), you will find the XSLT source. That's the transformation definition that given an input similar to what you used to generate it, it will generate an HTML page in output.

If you are just interested in the specific HTML output of that particular transformation, you may want to save the preview (there is a Save button at the left of the preview window, which is usually displayed at the bottom of Stylus Studio); if you are interested in re-executing the transformation against different sources, then you want to keep the XSLT around and re-run it later.

Minollo

Postnext
marcel hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marcel hijma
Date: 02 Mar 2006 10:40 AM
OK so am i missing something ?

I saved an XSL file with the name: stock1 (made made from the Stock video example)

So how can i execute this then ?

I just want to run this file with that soap request in it ...

Am i missing something ?

Thanks: marcel

Postnext
Minollo I.Subject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: Minollo I.
Date: 02 Mar 2006 10:45 AM
If you want to run it from inside Stylus Studio, just press the green, triangle shaped, preview button.

If you want to run it outside Stylus Studio from the command line, you can use the stylusxslt.exe command line utility.

If you want to run it outside Stylus Studio from your Java application, you can select the Saxon or Xalan processor from the Scenario settings, and ask Stylus Studio to generated the code for you (under the XSLT menu).

Minollo

Postnext
marcel hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marcel hijma
Date: 02 Mar 2006 03:23 PM
Originally Posted: 02 Mar 2006 01:59 PM
Minollo somehow i still don't get it: I just want to use this webservice inside an HTML or javascript. Isn't this what this tool is for ?<br> <br> So I create a Webservice / Incorporate this in a HTML/XML or XSL document and then i could use it from my browser (or from a java program, or from a javascript etc) ?? <br> <br> <br> I don't understand all the difficult stuff about Saxon options etc. what am i missing ?? After i created my XSL or XML i don't need stylus up and running anymore I suppose ? <br> (well unitl i make a new program again)

Postnext
Minollo I.Subject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: Minollo I.
Date: 02 Mar 2006 03:21 PM
Marcel,
let me try to summarize in steps what you are trying to do:

#1: you are invoking a web service, and getting back a result in XML format (a SOAP response)
#2: you want to create an HTML presentation containing data from the XML response of #1
#3: to achieve #2, you write an XSLT that given a SOAP response in input (#1) it generates an HTML output (#2)
#4: you want to be able to invoke the XSLT you have generated in #3 over and over again, also outside of the Stylus Studio UI environment, creating a fresh HTML report every time

Are we in agreement on that?
So, my understanding is that you have been able to do #1, #2 and #3; but you are having problems to do #4, but you have at least a couple of options:

A) You can run the XSLT you have created using StylusXslt.exe, which is a command line shipped with Stylus Studio (in the <install>\bin folder) that allows you to invoke the Stylus Studio XSLT processor out the UI environment. You can specify the source (the same web service call you are probably using now to preview the retul inside Stylus Studio), and the output location (where the HTML needs to be saved)

B) You can ask Stylus Studio to generate Java code to run the transformation as part of a Java application; to do that, you need to instruct Stylus Studio to use a Java-based XSLT processor; Saxon or XalanJ are your options; to do that, open you XSLT file in Stylus Studio, do XSLT > Scenario Properties..., click on the Processor tab and choose Saxon 8.x, for example, as your process. The choose XSLT > Generate Java Code, and Stylus Studio will generate Java code that you can either run standalone or you can embed in your application; that will run the same XSLT you have been designing

Does this make things any more clear?
Minollo

Postnext
marcel hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marcel hijma
Date: 02 Mar 2006 03:56 PM
Thanks Minollo that is clear.

So I can only invoke this all by making a java program and use that inside a java applet or so ?

So i can not directly use this XML. Make sense I must say , now i see the javac ...

Thanks I am going to work on it ..

Postnext
marcel hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marcel hijma
Date: 02 Mar 2006 04:10 PM
OK Minollo i ran it and just to finish this: there was a (probably) small error (I think):



C:\Program Files\Java\jre1.5.0_06\bin\java.exe -classpath C:\PROGRA~1\STYLUS~1\bin\CUSTOM~1.JAR;C:\PROGRA~1\STYLUS~1\examples\JAVAEX~1;C:\PROGRA~1\STYLUS~1\examples\Adapters;C:\PROGRA~1\STYLUS~1\sources;C:\PROGRA~1\STYLUS~1\bin\saxon8sa.jar;C:\PROGRA~1\STYLUS~1\bin\XML-AP~1.JAR jajaja
License file saxon-license.lic not found
The file saxon-license.lic required by com.saxonica.validate.SchemaAwareConfiguration
was not found in your classpath. The non-schema aware processor will be used instead.
ws:///ok.wscc:2,15: (Error) Error reported by XML parser: Document is invalid: no grammar found.
ws:///ok.wscc:2,15: (Error) Error reported by XML parser: Document root element "soap:Envelope", must match DOCTYPE root "null".
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<table width="100%" border="1">
<tbody>
<tr>
<td width="50%">IBM</td>
<td width="50%">79.90</td>
</tr>
<tr>
<td width="50%">MSFT</td>
<td width="50%">26.9801</td>
</tr>
</tbody>
</table>
</body>
</html>

Postnext
Minollo I.Subject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: Minollo I.
Date: 02 Mar 2006 04:28 PM
Saxon by default turns on validation of the input document; in the same tab where you chose the proessor, click on the "Settings..." button and click on "None" next to "Source document validation", close to the bottom. Generate the code again, and you should be all set.

Minollo

Postnext
marc hijmaSubject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: marc hijma
Date: 03 Mar 2006 05:53 AM
Ok thanks Minollo.
SO the only option to quickly incorporate or invoke these xml/soap data is via a java program ?
Isn't there another way ? For example via a jAVASCRIPT ?

Can't i just use this XSLT file from a script of something like that ?

Thanks: marcel










Posttop
Minollo I.Subject: From Webservice to XML HTTP/XML where is XMLTOHTML ??
Author: Minollo I.
Date: 03 Mar 2006 09:17 AM
Using XSLT from a script would be fairly easy; making it rely on SOAP response data returned by a web service invocation might be trickier.

I don't have experience with that; you may want to try googling the topic around...

Minollo

 
Topic Page 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Go to previous topicPrev TopicGo to next topicNext Topic
Download A Free Trial of Stylus Studio 6 XML Professional Edition Today! Powered by Stylus Studio, the world's leading XML IDE for XML, XSLT, XQuery, XML Schema, DTD, XPath, WSDL, XHTML, SQL/XML, and XML Mapping!  
go

Log In Options

Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio® and DataDirect XQuery ™are from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2016 All Rights Reserved.