Sunday, June 5, 2011

Hi, routing problem localization

I'm trying to translate my application, works fine but I have a
problem when changing the language,
mi default language is english, but also work with Spanish


this is my url has the lang tag.

http://localhost/caketra/articles/index/lang:eng

but my intention is to display in this way

http://localhost/caketra/eng/articles/index/ or
http://localhost/caketra/spa/articles/index/

and I use
.
Router:: connect ('/: lang /: controller /: action / *'
array (),
array ('lang' => '[a-z] {3 }'));

I can I translate the main page without problems but when I see the
details of an article I have this url

http://localhost/caketra/articles/view/1

but when I click on Spanish language I have this errors

http://localhost/caketra/articles/view/lang:spa

I lose article's ID and see the / lang: spa, at the end of the url

how I can solve this????


pd, sorry but my english is not very good.

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php

No comments: