Перенос MODX Revolution на хостинг. Восстановление сайта из бекапа
27
дек
2015
В данном видео уроке рассмотрим перенос сайта на MODX Revolution на хостинг. Восстановление сайта на MODX Revolution из бекапа.
Код файла
Смотрите также:
Комментарии ()
Услуги по MODX Revolution
Посмотреть все услуги
Оптимизация сайта
Подробнее & Заказать
Создание сайта на MODX Revolution
Подробнее & Заказать
Перенос сайта на MODX Revolution
Подробнее & Заказать
$modx->setOption(\'cultureKey\', \'ru\');
добавить setlocale(LC_ALL, \'ru_RU.utf-8\');
У меня три языка на сайте.
Работает как-то косо.
Вот дописанный код плагина:
<?php
$lankey = substr($_SERVER[\'REQUEST_URI\'], 1, 2);
if($modx->context->get(\'key\') != \«mgr\»){
//grab the current domain from the http_host option
switch ($lankey) {
case \'en\':
//switch the context
$modx->switchContext(\'en\');
//set the cultureKey
$modx->setOption(\'cultureKey\', \'en\');
break;
case \'ua\':
//switch the context
$modx->switchContext(\'ua\');
//set the cultureKey
$modx->setOption(\'cultureKey\', \'ua\');
break;
default:
// Set the default language/context here
$modx->switchContext(\'web\');
$modx->setOption(\'cultureKey\', \'ru\');
break;
}
}
Почему-то на главной не появляются ссылки, по которым осуществляется переход
Не появляются ссылки-переходы на страницы сайта.
В чем может быть проблема?
У меня три я зыка, я переписала код вот как:
<?php
$lankey = substr($_SERVER[\'REQUEST_URI\'], 1, 2);
if($modx->context->get(\'key\') != \«mgr\»){
//grab the current domain from the http_host option
switch ($lankey) {
case \'en\':
//switch the context
$modx->switchContext(\'en\');
//set the cultureKey
$modx->setOption(\'cultureKey\', \'en\');
break;
case \'ua\':
//switch the context
$modx->switchContext(\'ua\');
//set the cultureKey
$modx->setOption(\'cultureKey\', \'ua\');
break;
default:
// Set the default language/context here
$modx->switchContext(\'web\');
$modx->setOption(\'cultureKey\', \'ru\');
break;
}
}
Не появляются ссылки-переходы на страницы сайта.
В чем может быть проблема?
У меня три я зыка, я переписала код вот как:
<?php
$lankey = substr($_SERVER[\'REQUEST_URI\'], 1, 2);
if($modx->context->get(\'key\') != \«mgr\»){
//grab the current domain from the http_host option
switch ($lankey) {
case \'en\':
//switch the context
$modx->switchContext(\'en\');
//set the cultureKey
$modx->setOption(\'cultureKey\', \'en\');
break;
case \'ua\':
//switch the context
$modx->switchContext(\'ua\');
//set the cultureKey
$modx->setOption(\'cultureKey\', \'ua\');
break;
default:
// Set the default language/context here
$modx->switchContext(\'web\');
$modx->setOption(\'cultureKey\', \'ru\');
break;
}
}