Просмотр поста

.
diabloser

форма

echo '<form action="profile.php?act=settings" method="post" >' .
             '<div class="menu"><p><h3>' . $lng['settings_clock'] . '</h3>' .
             '<input type="text" name="timeshift" size="2" maxlength="3" value="' . core::$user_set['timeshift'] . '"/> ' . $lng['settings_clock_shift'] . ' (+-12)
' .
             '<span style="font-weight:bold; background-color:#CCC">' . date("H:i", time() + (core::$system_set['timeshift'] + core::$user_set['timeshift']) * 3600) . '</span> ' . $lng['system_time'] .
             '</p><p><h3>' . $lng['system_functions'] . '</h3>' .
             '<input name="direct_url" type="checkbox" value="1" ' . (core::$user_set['direct_url'] ? 'checked="checked"' : '') . ' />&#160;' . $lng['direct_url'] . '
' .
             '<input name="avatar" type="checkbox" value="1" ' . (core::$user_set['avatar'] ? 'checked="checked"' : '') . ' />&#160;' . $lng['avatars'] . '<br/>' .
             '<input name="smileys" type="checkbox" value="1" ' . (core::$user_set['smileys'] ? 'checked="checked"' : '') . ' />&#160;' . $lng['smileys'] . '<br/>' .
             '<input name="digest" type="checkbox" value="1" ' . (core::$user_set['digest'] ? 'checked="checked"' : '') . ' />&#160;' . $lng['digest'] .
             '</p><p><h3>' . $lng['text_input'] . '</h3>' .
             '<input type="text" name="field_h" size="2" maxlength="1" value="' . core::$user_set['field_h'] . '"/> ' . $lng['field_height'] . ' (1-9)
';
        if(core::$lng_iso == 'ru' || core::$lng_iso == 'uk') echo '<input name="translit" type="checkbox" value="1" ' . (core::$user_set['translit'] ? 'checked="checked"' : '') . ' />&#160;' . $lng['translit'];
        echo '</p><p><h3>' . $lng['apperance'] . '</h3>' .
             '<input type="text" name="kmess" size="2" maxlength="2" value="' . core::$user_set['kmess'] . '"/> ' . $lng['lines_on_page'] . ' (5-99)
' .
             '<input name="quick_go" type="checkbox" value="1" ' . (core::$user_set['quick_go'] ? 'checked="checked"' : '') . ' />&#160;' . $lng['quick_jump'] .
             '</p>';

        // Выбор Wap темы оформления
        echo '<p><h3>Wap ' . $lng['design_template'] . '</h3><select name="wapskin">';
        foreach (glob('../theme/*/style.css') as $val) {
            $dir = explode('/', dirname($val));
            $theme = array_pop($dir);
if (file_exists("../theme/$theme/.web"))continue;
            echo '<option' . (core::$user_set['wapskin'] == $theme ? ' selected="selected">' : '>') . $theme . '</option>';
        }
        echo '</select></p>';
        
// Выбор Web темы оформления
        echo '<p><h3>Web ' . $lng['design_template'] . '</h3><select name="webskin">';
        foreach (glob('../theme/*/style.css') as $val) {
            $dir = explode('/', dirname($val));
            $theme = array_pop($dir);
if (file_exists("../theme/$theme/.wap"))continue;
            echo '<option' . (core::$user_set['webskin'] == $theme ? ' selected="selected">' : '>') . $theme . '</option>';
        }
        echo '</select></p>';

        // Выбор языка
        if (count(core::$lng_list) > 1) {
            echo '<p><h3>' . $lng['language_select'] . '</h3>';
            $user_lng = isset(core::$user_set['lng']) ? core::$user_set['lng'] : core::$lng_iso;
            foreach (core::$lng_list as $key => $val) {
                echo '<div><input type="radio" value="' . $key . '" name="iso" ' . ($key == $user_lng ? 'checked="checked"' : '') . '/>&#160;' .
                     (file_exists('../images/flags/' . $key . '.gif') ? '<img src="../images/flags/' . $key . '.gif" alt=""/>&#160;' : '') .
                     $val .
                     ($key == core::$system_set['lng'] ? ' <small class="red">[' . $lng['default'] . ']</small>' : '') .
                     '</div>';
            }
            echo '</p>';
        }

        echo '<p><input type="submit" name="submit" value="' . $lng['save'] . '"/></p></div></form>' .
             '<div class="phdr"><a href="profile.php?act=settings&amp;reset">' . $lng['reset_settings'] . '</a></div>';
}