Главная > Компьютеры / DataLife Engine > Красивая оффлайн страничка с обратным отсчетом

Красивая оффлайн страничка с обратным отсчетом


23 апреля 2016 14:34. Разместил: Altyn

dle-offline

Открываем: \engine\modules\offline.php
Ищем:
$config['offline_reason'] = str_replace('"', '"', $config['offline_reason']);

$tpl->set('{reason}', $config['offline_reason']);

Меняем на:
$config['offline_reason'] = str_replace('"', '"', $config['offline_reason']);
$config['year'] = str_replace('"', '"', $config['offline_year']);
$config['month'] = str_replace('"', '"', $config['offline_month']);
$config['date'] = str_replace('"', '"', $config['offline_date']);
$config['hour'] = str_replace('"', '"', $config['offline_second']);
$config['minute'] = str_replace('"', '"', $config['offline_minute']);
$config['percent'] = str_replace('"', '"', $config['percent']);

$tpl->set('{reason}', $config['offline_reason']);
$tpl->set('{year}', $config['offline_year']);
$tpl->set('{month}', $config['offline_month']);
$tpl->set('{date}', $config['offline_date']);
$tpl->set('{hour}', $config['offline_hour']);
$tpl->set('{minute}', $config['offline_minute']);
$tpl->set('{percent}', $config['percent']);

Открываем: \engine\inc\options.php
Ищем:
showRow( $lang['opt_sys_reason'], $lang['opt_sys_reasond'], "<textarea class=\"edit bk\" style=\"width:350px;height:100px;\" name=\"save_con[offline_reason]\">{$config['offline_reason']}</textarea>" );

Ниже вставляем:
showRow( $lang['opt_sys_percent'], $lang['opt_sys_reasond'], "<b>Формат чисел:</b> 2010, 12, 23, 07, 30<br /><br />
<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">
  <tr>
    <td><textarea class=\"edit bk\" style=\"width:50px;height:14px; text-align: center;\" name=\"save_con[offline_year]\">{$config['offline_year']}</textarea></td>
    <td><textarea class=\"edit bk\" style=\"width:50px;height:14px; text-align: center;\" name=\"save_con[offline_month]\">{$config['offline_month']}</textarea></td>
    <td><textarea class=\"edit bk\" style=\"width:50px;height:14px; text-align: center;\" name=\"save_con[offline_date]\">{$config['offline_date']}</textarea></td>
    <td><textarea class=\"edit bk\" style=\"width:50px;height:14px; text-align: center;\" name=\"save_con[offline_hour]\">{$config['offline_hour']}</textarea></td>
    <td><textarea class=\"edit bk\" style=\"width:50px;height:14px; text-align: center;\" name=\"save_con[offline_minute]\">{$config['offline_minute']}</textarea></td>
  </tr>
  <tr>
    <td><div align=\"center\">Год</div></td>
    <td><div align=\"center\">Месяц</div></td>
    <td><div align=\"center\">Число</div></td>
    <td><div align=\"center\">Часов</div></td>
    <td><div align=\"center\">Минут</div></td>
  </tr>
</table>
" );
showRow( $lang['opt_sys_percent2'], $lang['opt_sys_reasond'], "<textarea class=\"edit bk\" style=\"width:50px;height:14px; text-align: center;\" name=\"save_con[percent]\">{$config['percent']}</textarea>" );

Открываем: \language\Russian\adminpanel.lng
В любое место вставляем:
'opt_sys_percent'        =>    "Дата завершения технических работ:",
'opt_sys_percent2'        =>    "Процентов до завершения технических работ:",

Красивая оффлайн страничка с обратным отсчетом

Вернуться назад