So I just found out 2 days ago about how useful XSLT is and been on it sinds then. But then I made a sample code in IronPython and I say allot of benefits for me because Im more in that kind of scripting/programming then the XSLT way. But what are the pros and cons of both? Is it just 2 ways of doing stuff or is one more optimized to do something than the other? I'd like details if you have them and if you have docs or links about it, it would be greatly appriciated.
I think this post is more directed to the developers of Umbraco, what was the purpose of implementing both? was it just to be able to support the languages(so you gave the option to choose) or was there a specifiec though about it?
I'd be interested to see your Python script - just curious. :-D
Obviously the key thing here is that Umbraco is flexible enough to allow developers to use various technologies - .NET, XSLT, IronPython, IronRuby (and other DLRs).
For a lot of developers who come to Umbraco are from a .NET background, which generally means that user-controls and XSLT are more familiar than Python - hence why there are more examples on the wiki, blogs, etc.
Since the content is cached as XML, XSLT is the ideal technology to transform that into HTML (or any other mark-up - RSS, XML, PDF, etc).
The implementation of IronPython pre-dates my involvement with Umbraco, I believe it was introduced because there was a specific requirement for it... then it was a case of "why not keep it in?" - keeping options open.
At the end of the day, its more important to use a technology you are comfortable with, than struggle with a steep learning curve. (Lets just say that a LOT of beginners struggle to grasp the concepts of XSLT - but when they "get it", they "get it"!
The script was generated with the template Subpages From Current Page. I dont know IronPython yet :P I was just curious about the syntax and I loved it on sight :D
XSLT is something I need to get used to, I'll get it eventually but i'm also(/more) interested in IronPython :) maybe i'll just learn both of them :P
But I'm thinking of splitting the tasks: XSLT for mostly node tasks (CMS stuff) and IronPython when I need to get deeper into the library's.
I dont like to use two languages for the same purpose, in my eyes its redundant and chaotic. Sure I know I can access the Umbraco library in the XSLT and I dont doubt i'll be using that but more as utils (NiceURL etc.)
Do you have any (general) advise on these languages?
Hi Bryan, I have been using xslt in Umbraco for a year and I like it, most because its closeness to xhtml. But - I now decided to start using Python for a new project, and I must say I am very happy with how it has started out. The code is much easier to write and read (imho) + it's easier to build a set of modules / classes to reuse than in xslt. For a vb/c/java/pascal-coder the python language is very comfortable.
XSLT and IronPython
Hey guys,
So I just found out 2 days ago about how useful XSLT is and been on it sinds then. But then I made a sample code in IronPython and I say allot of benefits for me because Im more in that kind of scripting/programming then the XSLT way. But what are the pros and cons of both? Is it just 2 ways of doing stuff or is one more optimized to do something than the other? I'd like details if you have them and if you have docs or links about it, it would be greatly appriciated.
I think this post is more directed to the developers of Umbraco, what was the purpose of implementing both? was it just to be able to support the languages(so you gave the option to choose) or was there a specifiec though about it?
Thanks a bunch!
Bryan
Hi Bryan,
I'd be interested to see your Python script - just curious. :-D
Obviously the key thing here is that Umbraco is flexible enough to allow developers to use various technologies - .NET, XSLT, IronPython, IronRuby (and other DLRs).
For a lot of developers who come to Umbraco are from a .NET background, which generally means that user-controls and XSLT are more familiar than Python - hence why there are more examples on the wiki, blogs, etc.
Since the content is cached as XML, XSLT is the ideal technology to transform that into HTML (or any other mark-up - RSS, XML, PDF, etc).
The implementation of IronPython pre-dates my involvement with Umbraco, I believe it was introduced because there was a specific requirement for it... then it was a case of "why not keep it in?" - keeping options open.
At the end of the day, its more important to use a technology you are comfortable with, than struggle with a steep learning curve. (Lets just say that a LOT of beginners struggle to grasp the concepts of XSLT - but when they "get it", they "get it"!
Cheers, Lee.
Hey Lee,
The script was generated with the template Subpages From Current Page. I dont know IronPython yet :P I was just curious about the syntax and I loved it on sight :D
XSLT is something I need to get used to, I'll get it eventually but i'm also(/more) interested in IronPython :) maybe i'll just learn both of them :P
But I'm thinking of splitting the tasks: XSLT for mostly node tasks (CMS stuff) and IronPython when I need to get deeper into the library's.
I dont like to use two languages for the same purpose, in my eyes its redundant and chaotic. Sure I know I can access the Umbraco library in the XSLT and I dont doubt i'll be using that but more as utils (NiceURL etc.)
Do you have any (general) advise on these languages?
Peace,
Bryan
Hi Bryan, I have been using xslt in Umbraco for a year and I like it, most because its closeness to xhtml. But - I now decided to start using Python for a new project, and I must say I am very happy with how it has started out. The code is much easier to write and read (imho) + it's easier to build a set of modules / classes to reuse than in xslt. For a vb/c/java/pascal-coder the python language is very comfortable.
Frankly I don't think I will use a single xslt macro in my new project. All python. Take a look at the thread http://our.umbraco.org/forum/developers/extending-umbraco/11296-IronPython-lab if you like. There are some thoughts and hopefully some useful snippets.
Regards!
Jonas
I'll be keeping a eye on the topic ^^
is working on a reply...