Requesting full URL incl. all querystring parameters?
Hi there.
I'm currently working on a project where I need n-amount of "boxes" on the pages. These boxes contains n-amount of links, news, downloads, reviews etc.
My problem is, that these boxes has to be able to expand/collapse when clicking on a +/- link.
As for now, I've made this work requesting a query parameter, but this only works on one box at a time even though I use different query string parameters for each of the boxes.
The problem is, that the query string is overwritten when I click the on the +/- links.
I need some way to be able to request the full URL incl. all existing query parameters, or at least a way to request the full list of query parameters.
I figured then I could use some sort of concatenation in combination with xsl-choose/when/otherwise , so I can check whether a parameter exists already, and if not, I can add it to the existing "list" of parameters.
I really hope you can help me out here.
NB.
Using Javascript/AJAX for the +/- functionality is not an option. I could create the "boxes" as usercontrols instead of xslt's, but I figured, since there is no user-input, it would be overkill.
Using some sort of XSLTHelper class would be an option, but I have no idea how to use an helper-class and use it together with an xslt in umbraco.
That would do the trick I think, but then I have to know which parameters occurs.
Using a helper class that returns the full query string parameter list is more "generic" and reusable. this way I don't have to know all the parameters, all I need to is to check if the parameter I need exists , if not then add it to the existing query parameter list :)
I've created such a helper class, but how do I import it and use it with umbraco? I think I have to register the helper.dll in some sort of web.config , so Umbraco knows where to look for it? and how do I register the helper inside the xslt? so it knows where to look for the function I've created?
Requesting full URL incl. all querystring parameters?
Hi there.
I'm currently working on a project where I need n-amount of "boxes" on the pages. These boxes contains n-amount of links, news, downloads, reviews etc.
My problem is, that these boxes has to be able to expand/collapse when clicking on a +/- link.
As for now, I've made this work requesting a query parameter, but this only works on one box at a time even though I use different query string parameters for each of the boxes.
The problem is, that the query string is overwritten when I click the on the +/- links.
I need some way to be able to request the full URL incl. all existing query parameters, or at least a way to request the full list of query parameters.
I figured then I could use some sort of concatenation in combination with xsl-choose/when/otherwise , so I can check whether a parameter exists already, and if not, I can add it to the existing "list" of parameters.
I really hope you can help me out here.
NB.
Using Javascript/AJAX for the +/- functionality is not an option. I could create the "boxes" as usercontrols instead of xslt's, but I figured, since there is no user-input, it would be overkill.
Using some sort of XSLTHelper class would be an option, but I have no idea how to use an helper-class and use it together with an xslt in umbraco.
I have done something in the past like this
[code]
Printer friendly
[/code]
That would do the trick I think, but then I have to know which parameters occurs.
Using a helper class that returns the full query string parameter list is more "generic" and reusable. this way I don't have to know all the parameters, all I need to is to check if the parameter I need exists , if not then add it to the existing query parameter list :)
I've created such a helper class, but how do I import it and use it with umbraco? I think I have to register the helper.dll in some sort of web.config , so Umbraco knows where to look for it? and how do I register the helper inside the xslt? so it knows where to look for the function I've created?
I found the answer to my last question here:
http://en.wikibooks.org/wiki/Umbraco/Createxsltexstensionlikeumbraco.LibraryinC
Thanks a lot for the help.
Regards,
Martin
is working on a reply...