Added translation using phrases

. added translation functionality by
-- adding loadPhrases-method in Controllers
-- replacing hardcoded html-text with $this->p->t(...)
This commit is contained in:
Cris
2018-05-09 12:36:35 +02:00
parent 8c00fb7be5
commit 1254e8d618
18 changed files with 274 additions and 268 deletions
+20 -21
View File
@@ -1,22 +1,21 @@
<?php
class Nation_widget extends DropdownWidget
{
public function display($widgetData)
{
// Nation
$this->load->model('codex/nation_model', 'NationModel');
$this->NationModel->addOrder('nation_code');
$this->addSelectToModel($this->NationModel, 'nation_code', 'kurztext');
$this->setElementsArray(
$this->NationModel->load(),
true,
'Nation wählen...',
'keine Nation gefunden'
);
$this->loadDropDownView($widgetData);
}
<?php
class Nation_widget extends DropdownWidget
{
public function display($widgetData)
{
// Nation
$this->load->model('codex/nation_model', 'NationModel');
$this->NationModel->addOrder('nation_code');
$this->addSelectToModel($this->NationModel, 'nation_code', 'kurztext');
$this->setElementsArray(
$this->NationModel->load(),
true,
$this->p->t('ui', 'bitteEintragWaehlen')
);
$this->loadDropDownView($widgetData);
}
}