dumbdare
Jan 3rd, 2006, 10:47 AM
Dear all,
I'm trying to integrate a content management system with Tiles under Spring but am having problems with escaped characters in the request URL and mapping the consequent view to a tile definition. For example if I have a Tile definition with the name "My Page" and I request "/foo/bar/My%20Page.html" then the UrlFileNameViewController uses the My%20Page as the view name and hence the tile definition is not resolved (note that I can request "/foo/bar/My Page" but the browser quite rightly escapes the whitespace to %20). I realise that the tile definition name is a literal name and not a url but is there any way to unescape Url escaped characters before hitting the view resolver (or is there a view resolver that actually does this)?
I can't believe this is not possible, and someone somewhere must have hit a similar problem. Overiding the url view controller with a custom controller seems a bit overkill/hacky for something so simple.
I'm a bit of a newbie at Tiles and Spring so bear with me if the answer is in fact obvious (usual wood-for-the-trees effect!).
Dumbdare
p.s. searched the forums but only found one other relevant post that didn't really answer my question, hence new thread
I'm trying to integrate a content management system with Tiles under Spring but am having problems with escaped characters in the request URL and mapping the consequent view to a tile definition. For example if I have a Tile definition with the name "My Page" and I request "/foo/bar/My%20Page.html" then the UrlFileNameViewController uses the My%20Page as the view name and hence the tile definition is not resolved (note that I can request "/foo/bar/My Page" but the browser quite rightly escapes the whitespace to %20). I realise that the tile definition name is a literal name and not a url but is there any way to unescape Url escaped characters before hitting the view resolver (or is there a view resolver that actually does this)?
I can't believe this is not possible, and someone somewhere must have hit a similar problem. Overiding the url view controller with a custom controller seems a bit overkill/hacky for something so simple.
I'm a bit of a newbie at Tiles and Spring so bear with me if the answer is in fact obvious (usual wood-for-the-trees effect!).
Dumbdare
p.s. searched the forums but only found one other relevant post that didn't really answer my question, hence new thread