Hi,

I am looking for a solution to the following problem: basically, I
want urls in form "/controller/action/params" as well as "/en/
controller/action/params". The idea behind this is to allow for
multiple languages ("/en/..." might as well be replaced with "/cs/..."
and alike) and in ideal case, I would like the language identifier to
be available as a global variable. This would allow me to use the
variable in model (and also controller & view) classes, in the
following fashion, for example:

class Hotel extends AppModel {
  var $hasOne = array("HotelTxt" => array("conditions" =>
"lang={lang}"));
}

In other words, whenever an url like "/cs/*" or "/en/*" is
encountered, I need to store the "cs"/"en" part into a global var and
effectively go to url "*" instead. Can this be achieved via cakephp
routing? Or should I approach to the problem in a completely different
manner?

Thanks for your ideas,
Petr K.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to