-- Nathan Bell <[EMAIL PROTECTED]> wrote (on Tuesday, 14 August 2007, 05:40 PM -0700): > I do not remember if this is the case or not, but I believe you have to attach > "/*" to the end of routes that you want to allow parameters on. For instance: > > Route: /:module/:lang/:controller/:action/* > URL: /admin/en/employee/add/id/2 > > Should work as expected. With out that '/*' at the end, I believe the router > will ignore the trailing parameters, or ignore your route all together and use > the default route ( /:module/:controller/:action/* )
That's correct: a trailing '/*' (wildcard route) will allow the route to have key/value pairs trailing the primary route definition. > ashish.sharma wrote: > > Hello, It's really a gr8 forum for a developer like me who is learning > Zend > and facing so many technical issues/problems. I have resolved many > problems > by my own using the help available and by the help of some members on this > forum. Thanks to all. The problem now I am facing is related with Router > rewrite .. here is the problem. I am creating a multi-lingual site and I > am > using the following router rewrite string in my BOOTSTRAP file. :module > /:lang/:controller/:action Which results the URL as : > admin/en/employee/add > .. which is working fine and I am able to open the add section and can add > records. In the above URL it is returning me the right names of module, > controller & action if I use requests's methods to print them i.e. > getModuleName, getControllerName etc .. Now the problem comes when i click > on "edit entry" which is having a URl like admin/en/employee/edit/id/2 .. > this is not working fine and redirect to Access denied page as i have > implemented ACL. But I have provided "edit" permission to the User = > "ADMIN" and i am logged in with the same User. When i print the Module & > Controller name it is giving "en" as controller. I feel that this is > causing the problem. On further tracking i found that whenever i use and > parameter next to action .. add or edit it gives me the error. Any > suggestions ? Thanks Ashish Sharma -- Matthew Weier O'Phinney PHP Developer | [EMAIL PROTECTED] Zend - The PHP Company | http://www.zend.com/
