In my cakePHP-environment (version 2) the following code in
AppController:
$locale = $this->Session->read('Config.language');
//if ($locale && file_exists(VIEWS . DS . $this-
>viewPath .DS . $locale . DS)) {
if ($locale && file_exists($_SERVER['DOCUMENT_ROOT'] . '/
cake2/
app/View/Pages/'.$locale.'/')) {
echo $this->viewPath . DS . $locale;
$this->viewPath = $this->viewPath . DS . $locale;
}
Everything works fine. But the outcommented line is how to do it (in
cakephp-style). But it doesn't work in my example. Does anybody know
what I do wrong? There is no error message. My pages structure ist the
following:
- default files: View/Pages/
- files in another language: View/Pages/deu, View/Pages/ita etc.
Thank you for any help.
Ivo
--
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:
Post a Comment