Welcome, Guest. Register Now!
   
Mark Forums Read Mark Forums Read Mark Forums Read


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-21-2008, 05:06 PM
Junior Member
 
Join Date: Dec 2007
Posts: 8
Default Zend_Translate & modular directory structure

Does anybody know how i can combine zend_translate with a modular directory structure?

First i tried to add the translations directly into the module like so:

default/translations
default/controllers

In my IndexController.php i added:

public function init()
{
$this->_translation = new Zend_Translate(adapter, '../translations', null, array('scan' => Zend_Translate::LOCALE_DIRECTORY));
}

without any luck, then i tried:

translations/en/default/index/index
application/default/presenters/IndexController.php

added to my bootstrap:

$tr = new Zend_Translate(adapter, 'translations', null, array('scan' => 2));
$reg->set('tr', $tr);

and changed my init() to:

public function init()
{
// the registry key is set in my bootstrap
$this->_translation = Zend_Registry::get('tr');
}

but this does not function either.. and i doubt that using translations/en/index/index will work, maybe translations/module/en/index/index?

all help is greatly appreciated
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 12:26 PM.