|
From: <pan...@us...> - 2008-09-20 19:59:32
|
Revision: 360
http://acmcontester.svn.sourceforge.net/acmcontester/?rev=360&view=rev
Author: panzaboi
Date: 2008-09-20 19:59:23 +0000 (Sat, 20 Sep 2008)
Log Message:
-----------
Small fixes.
Added 2nd language
Modified Paths:
--------------
website/library/Application.php
website/library/Ostacium/Controller/Action.php
Added Paths:
-----------
website/lang/en.csv
website/lang/uk.csv
Modified: website/library/Application.php
===================================================================
--- website/library/Application.php 2008-09-20 19:57:45 UTC (rev 359)
+++ website/library/Application.php 2008-09-20 19:59:23 UTC (rev 360)
@@ -38,7 +38,10 @@
$this->setupRoutes($frontController);
$frontController->dispatch();
}
- catch (Exception $e) {/*var_dump($e);*/}
+ catch (Exception $e)
+ {
+ //var_dump($e);
+ }
}
protected function _initialize()
@@ -76,9 +79,9 @@
// Setup Error Handler
$frontController->registerPlugin(new Zend_Controller_Plugin_ErrorHandler(array(
- 'module' => 'default',
- 'controller' => 'error',
- 'action' => 'error'
+ 'module' => $_config->auth->noacl->module,
+ 'controller' => $_config->auth->noacl->controller,
+ 'action' => $_config->auth->noacl->action
)));
// Setup Languages
@@ -196,11 +199,11 @@
$_config = Zend_Registry::get('config');
$_db = Zend_Registry::get('db');
- //$translate = new Zend_Translate('csv', $_config->lang->path . $_config->lang->default . '.csv', $_config->lang->default);
- //$translate->addTranslation('path/to/other.csv', 'fr');
+ $translate = new Zend_Translate('csv', $_config->lang->path . $_config->lang->default . '.csv', $_config->lang->default);
+ $translate->addTranslation($_config->lang->path . 'en.csv', 'en');
- //$translate->setLocale($_config->lang->default);
- //Zend_Registry::set('Zend_Translate', $translate);
+ $translate->setLocale($_config->lang->default);
+ Zend_Registry::set('Zend_Translate', $translate);
/**********************************************/
$user_messages = $_db->select()->from('messages')->query()->fetchAll();
Modified: website/library/Ostacium/Controller/Action.php
===================================================================
--- website/library/Ostacium/Controller/Action.php 2008-09-20 19:57:45 UTC (rev 359)
+++ website/library/Ostacium/Controller/Action.php 2008-09-20 19:59:23 UTC (rev 360)
@@ -40,6 +40,7 @@
foreach ($params as $key => $value)
{
+ if (is_array($value) || is_object($value)) continue;
$from[] = ($key == 'controller' || $key == 'action' ? $value : $key . '-' . $value);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|