Okay, I wanted to blog about that yesterday, but I ended up the site restyle at 4am and also if I was able to sleep only at 6am, I wasn’t going to blog with that insomnia. I wish to thank haran who doesn’t know me
He wrote some of the most beautiful webdesigns for OSWD, and are his most of the ones I used for my site (and its one of his heavy elaborated the one used for Ziotto website -note: it’s an Italian crazy and fun site of some friends of mine, and me, too
-).
This time using XSL I was able to abstract most of the work so that I just had to change a base template file to do most of the job, but I still have some problems with XSL that I want to nail down, for who wants to help me, in the second page I’ll show what I’m trying to do and does not work as I expected.. if you’re an XSL expert, please help me :’)
I think I understand what you are trying to do. However I don’t think it will work.
In the normal case you are passing an xpath to use in a select. In the downloads case you are trying to pass a nodeset or some text or something.
I think there is an extension function that will do some of what you want. Which is basically evaluate either to a nodeset from a nodeset or an xpath. Then you’d pass that as a parameter (I don’t know if that will work either). I think its commonly called eval() (or something similar.) Its probably in esxlt standard?
The better way to do it is to subtemplate and pass the template to use for the insides of the box as another parameter.
so in the box template instead of doing…
you do:
You’d then pass the name of a template to use for the insides of the box.
I think that would work, and give even more flexibility. However its been a long time since I did much in the way of xslt.
Ah crap… it stripped all the code…
Basically what you do it is you replate the apply-templates in the box fragment with a call-template that calls a template you passed as a parameter.
so:
[xsl:template name="box"]
…. open box stuff ….
[xsl:call-template name="$content_template"]
[xsl:with-param name="content"]
[xsl:value-of select="$content"/]
[/xsl:with-template]
[/xsl:call-template]
…. close box stuff ….
[/xsl:template]
I hope this is readable…
qhpdlgi lsrfy wadhv ighcwqdt dnfxckpb uczrfpnb bacsuhejx
http://alohousing.com