views:

164

answers:

8

Can any professional please specify some real world application, where he / she has used this XPath & XSLT for any logic / view?

It creates a great query among some of the people I've communicated with, and so I myself also wants to know about this. I wish that this question will create a starting point from where new developers will take home some practical experience.

Any help is greatly appreciated.

If possible, please try to provide how XPath & XSLT interpret your data for your application, which you want to share with us. This will be helpful for others to understand both the power of XSLT (& XPath), and also of your application.

+2  A: 

The Amaxus, Sitecore and Umbraco content management systems all use XSLT as a method of rendering content into markup. I use it for these purposes frequently. Can you be more specific on what you want to know?

Matt
How the real world applications (like the ones you specified) actually use the XSLT to their needs. Because normally server-side scripting (like Java, .Net, PHP) get highlighted, but these programming get a backseat. So any elaboration will greatly help curious people like me.
Knowledge Craving
In the applications that I mentioned above, the server-side code (PHP and two ASP.Net applications) respectively build an XML document (generally representing the user-entered content). This XML document is then transformed by one (or multiple) XSLT definitions to build either a whole HTML page or parts of a HTML page.The transformation is done server-side in the applications I'm talking about, and the result is cached as the XSL transformation does incur an overhead. This is usually so the client does not see the intermediate XML, which may contain information they should not be privy to.
Matt
+2  A: 

Not really sure what you are trying to get back. But I've used XPath and XSLT in a medium sized banking application. Mainly because the architects had designated we must use SOAP/JMS or SOAP/HTTP and the platform was WebSphere Process Server and WebSphere Message Broker.

Derek Clarkson
+2  A: 

OpenOffice.org uses XSLT filters to export its XML native format into a bunch of different formats (including PDF).

amphetamachine
+2  A: 

We use XSLT as almost a middleware because we have a lot of data available to us in XML (mostly articles etc.). So, to transform those XML files into xHTML, or at least some part of those, we use XSLT. So,

XML File --> (XSLT + some additional HTML) --> Transitional xHTML pages.

Also, there are some internal comparisons and conversion of one article format to the other.

Hope this helps.

AJ
+2  A: 

I used xslt/xpath extensively in one my projects. we were developing a windows gadget which gets an xml response to a web service. This xml is then parsed to xhtml.

Check out this open source project umbraco. They use xslt for templating. Check it for one of the widely used examples.

rAm
+3  A: 

My company's primary application is a data-entry program used by courtroom clerks. The data's entered into an in-memory ADO.NET data set, and the program generates many different read-only views of the data (including minute orders and probation orders) in the UI. Those views are produced in HTML by running various XSLT transforms on the data set's XML representation.

XSLT and XPath are extremely well-suited to this sort of problem. There's a small amount of preprocessing that we have to perform on the data (if a defendant is given 18 months on one charge and 25 months on another the order should say he's sentenced to three years and seven months, and while it may be possible to do that kind of calculation in XSLT it's not worth figuring out how), but by and large any business rule that the users have thrown at us over the course of the last few years have been simple to implement. ("The sentence on the extradition order that indicates that the defendant will be transported to the new jurisdiction if he's in custody also needs to indicate that he's excused from future court appearances, if there are any scheduled appearances at which the court required him to appear" turns out to be something that a simple XPath query can handle.)

And it's fast. We re-generate the HTML for a read-only view every time the user clicks on the tab containing the view, and you really can't tell.

Robert Rossney
Knowledge Craving
+1  A: 

Starcraft 2 (view source)

Mark
One of the best examples highlighted. Hats off to you!!!
Knowledge Craving
+1  A: 

I use it for building websites as a replacement for .aspx pages, and as a View Engine on MVC:

http://myxsl.net/

Max Toro