Yes, the parameter is now called "route".
Unfortunately the NVelocity view engine doesn't allow you to pass a dictionary
inside a dictionary, which is what you have to do to get this working.
So far I've been able to get around this restriction/bug by using, eg:
$Url.Link('Product Name', "%{route='ProductPage',
useCurrentRouteParams='true'}")
If this doesn't work for you then you have to process the url on your
controller and pass it to the view as a string.
Please raise this in the Uservoice or if you consider it a bug then raise it in
our issue tracker.
Cheers
John
________________________________
From: Ola Herrdahl <[email protected]>
To: [email protected]
Sent: Mon, 25 January, 2010 1:34:18 AM
Subject: Url.Link using named routes
The routing documentation
(http://www.castleproject.org/monorail/documentation/trunk/advanced/routing.html)
says that you can specify the current route using a parameter called named.
E.g. $Url.Link('Admin Home', "%{named='adminhome'}") but as far is I can tell,
the parameter is now called route, correct?
And how do you pass parameters to a route?
I want to do something like this:
$Url.Link('Product Name', "%{route='ProductPage', params={id=15,
name='ProductName'}}")
But I can't get it to work.
(The route will work if I construct the URL by hand so it is probably not a
problem with the configuration.)
Any ideas?
Regards,
Ola
--
You received this message because you are subscribed to the Google Groups
"Castle Project Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/castle-project-users?hl=en.
__________________________________________________________________________________
See what's on at the movies in your area. Find out now:
http://au.movies.yahoo.com/session-times/
--
You received this message because you are subscribed to the Google Groups
"Castle Project Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/castle-project-users?hl=en.