xsltprocessor

SQL -> MongoDB Export Performance Issues

I'm trying to set up an automated process to regularly transform and export a large MS SQL 2008 database to MongoDB. There is not a 1-1 correspondence between tables in SQL and collections in MongoDB -- for example the Address table in SQL is translated into an array embedded in each customer's record in Mongo and so on. Right now I ha...

How to specify xml documents to transform with resource collection in ant?

I'm trying to use ant to use XSLT to preprocess three specific stylesheets in my project. The Ant documentation for the xslt task says that it should be able to accept any resource collection. Specifically, it says: Use resource collections to specify resources that the stylesheet should be applied to. Use a nested mapper and the tas...

XSLT breaks jQuery/Prototype Script in Firefox

I am working on a school project. It's an internet page with XML / XSLT. For the design we thought about an image fading effect in the background. I made it as you can see and it works perfectly on IE7. But checking it in FF 3.6 throws some suspicious errors in firebug und does not work. For example: alert($('menu_bg').innerHTML); ...

XSLT, Doctype and Google-Map v3 not working

Hello, I'm trying to include a GoogleMap v3 (everything was okay with v2) in my HTML pages generated with XLS Transformations. My JS code comes from this page. Basically, the map works correctly when everything is in plain HTML, as per the example, however when I try to include it in the XSL stylesheet, Firefox (v3.6) complains and doe...

XSLT Stylesheet switcher

Is there a way to switch a CSS stylesheet using XSLT? We are trying to do this without Javascript or include different files based on what CSS Stylesheet is used. Example: XSLT for normal view. Click a link and switches the stylesheet to view a Text Only view for accessibility and screen readers to use. At the same time getting rid o...

Parsing HTML in Android: no XSLT? What to use?

In need in my application to fetch remote HTML document and parse some parts out of it. As I don't want to play with string parsing, which would be really lots of work, I thought about using XSLT, which would let me build small XML document out of HTML and then read it easy. Seems there is no XSLT support in Android? What other ways I c...

How can I render HTML from XML within an iframe?

I am making a REST call that returns XML from within a Widget in Zendesk using an <iframe/>. I would like to use XSLT to transform the XML into HTML that is rendered within the <iframe/> Is there any way I can write my XSLT inline, and have the <iframe/> somehow execute the xslt transformation, yielding the HTML to show in the <iframe/...

How to diagnose XSLT problems with Firefox?

Is there a way to see error messages / debug information on what happens when Firefox 3 applies an XSLT transformation? In Firefox I am getting only the content of the text nodes of the XML document. The stylesheet is in the same directory and is bound with <?xml-stylesheet ...>. In Internet Exporer it works fine and Altova XML Spy does ...

How to specify a sortBy through a javax.xml.transform.Transformer.transform() call?

I'm using javax.xml.transform.Transformer.transform() to convert one xml to another through an xsl stylesheet. I would like to programatically set the sorting of the first level of children, but am unsure how to go about it. I've checked out the docs, but I don't understand which type of property/parameter to use and how to specify in so...

How to pass js var in xslt

Hi All, I have a javascript variable something like: var str = "AA,BB,CC,AA,BB,DD"; var totlength = str.split(",").length; var xx = str.split(","); for (var i = 0; i < totlength; i++) { alert(xx[i]); } and I could print this value using above method.Now the problem is I have to craete on...

Can I include *.xslt in ASP.NET class library for internal use?

I want to use same xsl template in few websites. Can I add it into class library? If yes how can I Load it? Example of path, etc... ...

C++ XLST tranform not working using MSXML 3.0

Hi guys, I'm new to C++ and inherited the following code that is supposed to transform the given XML using the XSLT file to just spit out the text values. It loads both the XML and XSLT fine and the transformnode() call returns success but no transformation has been applied. The original output at the bottom contains the original XML i...

String functions missing in Xalan 2.7, java.lang.String used instead?!

I am using Xalan 2.7.0 (as bundled with Apache FOP 1.0) and have problems when using string functions. The line <xsl:value-of select="fn:replace('test', 't', '*')"/> results in this exception: javax.xml.transform.TransformerException: java.lang.IllegalArgumentException: argument type mismatch at org.apache.fop.cli.InputHandler.tran...

Using param in XSLT patterns

I am setting a xslt param with PHP, and then calling the transform. I want to use the param value in an XPath expression to grab the proper nodes, but this doesn't seem to be working. I am guess it's possible, I think I am just missing the syntax. Here what I have... PHP: $xslt->setParameter('','month','September'); XSL: <?xml versi...

Sitecore: Loop through media folder?

I have a Sitecore 4 solution, where i need to loop through a media folder and show all the files in that folder. I have an item with a link type. I have then choosen a file inside the folder. I then want to grab this file, and find the folder it excist in, and then loop through all the files in that folder, and show them. All this in x...

xsl:include and xsl:param at Google Chrome, with jQuery transform plugin

I've been trying to use XSL with Google Chrome, but with no success. I read that Chrome have some bugs with XSLT, and one of them is that it doesn't support xsl:include. Bug can be checked here: http://code.google.com/p/chromium/issues/detail?id=8441. After some research I found a new version of the transform plugin by Daer System, and i...

why is that IXSLTemplate::putref_stylesheet compile when passed an IXMLDOMDocument argument

hello I am playing with XSLT with MSXML2 for the first time. And of course it doesn't work :-) I have a bug which I cannot figure to solve. So as to fix the bug, I try to understand everything around: and something shocks me. void xsltProcessing(IXMLDOMDocument* pXmlDoc, IXMLDOMDocument * pXslDoc) { CComPtr<IXSLTemplate> pTemplate...

Nested loops does not work correctly for xslt

I have been using a CMS which is called Umbraco(umbraco.org) and for displaying flash news on the website using SlideShowPro Standalone product(www.slideshowpro.net) In brief I created a section on admin panel as follows. -Flash(which has a xslt file) - Month name - A node with image - A node with video Every mon...

IXSLTemplate::putref_stylesheet returns E_INVALIDARG

Well, it's been several hours I'm lost... IXSLTemplate::putref_stylesheet doesn't document any error except E_FAIL. However in my case putref_stylesheet returns E_INVALIDARG. GetErrorInfo() is only redundant telling me that the "Argument is invalid". So I am not left with much information. However my code is pretty close to all exampl...

Resolve relative paths when loading XSLT files

I've updated the question below Hello, I need to do a XSL transformation using Apache FOP and I have a code like this one: //Setup FOP Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF, out); //Setup Transformer Source xsltSrc = new StreamSource(new File(xslPath)); Transformer transformer = tFactory.newTransform...