Minor improvements (#264)

* Minor improvements

* Update CHANGELOG.md
This commit is contained in:
Roman Kelesidis 2023-09-25 00:25:06 +07:00 committed by GitHub
parent 1bddf265a2
commit 7054dbbb2d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 15 additions and 13 deletions

View File

@ -10,7 +10,7 @@
- Added missing translation in admin_ug_auth [\#254](https://github.com/torrentpier/torrentpier-lts/pull/254) ([belomaxorka](https://github.com/belomaxorka)) - Added missing translation in admin_ug_auth [\#254](https://github.com/torrentpier/torrentpier-lts/pull/254) ([belomaxorka](https://github.com/belomaxorka))
- Support for IDN domains [\#252](https://github.com/torrentpier/torrentpier-lts/pull/252) ([belomaxorka](https://github.com/belomaxorka), [kovalensky](https://github.com/kovalensky)) - Support for IDN domains [\#252](https://github.com/torrentpier/torrentpier-lts/pull/252) ([belomaxorka](https://github.com/belomaxorka), [kovalensky](https://github.com/kovalensky))
- Fixed cache directory auto-creating with SQLite [\#247](https://github.com/torrentpier/torrentpier-lts/pull/247) ([belomaxorka](https://github.com/belomaxorka)) - Fixed cache directory auto-creating with SQLite [\#247](https://github.com/torrentpier/torrentpier-lts/pull/247) ([belomaxorka](https://github.com/belomaxorka))
- Minor improvements [\#245](https://github.com/torrentpier/torrentpier-lts/pull/245), [\#246](https://github.com/torrentpier/torrentpier-lts/pull/246), [\#248](https://github.com/torrentpier/torrentpier-lts/pull/248), [\#249](https://github.com/torrentpier/torrentpier-lts/pull/249), [\#250](https://github.com/torrentpier/torrentpier-lts/pull/250), [\#251](https://github.com/torrentpier/torrentpier-lts/pull/251), [\#253](https://github.com/torrentpier/torrentpier-lts/pull/253), [\#255](https://github.com/torrentpier/torrentpier-lts/pull/255), [\#256](https://github.com/torrentpier/torrentpier-lts/pull/256), [\#257](https://github.com/torrentpier/torrentpier-lts/pull/257), [\#258](https://github.com/torrentpier/torrentpier-lts/pull/258), [\#259](https://github.com/torrentpier/torrentpier-lts/pull/259), [\#261](https://github.com/torrentpier/torrentpier-lts/pull/261), [\#262](https://github.com/torrentpier/torrentpier-lts/pull/262), [\#263](https://github.com/torrentpier/torrentpier-lts/pull/263) ([belomaxorka](https://github.com/belomaxorka)) - Minor improvements [\#245](https://github.com/torrentpier/torrentpier-lts/pull/245), [\#246](https://github.com/torrentpier/torrentpier-lts/pull/246), [\#248](https://github.com/torrentpier/torrentpier-lts/pull/248), [\#249](https://github.com/torrentpier/torrentpier-lts/pull/249), [\#250](https://github.com/torrentpier/torrentpier-lts/pull/250), [\#251](https://github.com/torrentpier/torrentpier-lts/pull/251), [\#253](https://github.com/torrentpier/torrentpier-lts/pull/253), [\#255](https://github.com/torrentpier/torrentpier-lts/pull/255), [\#256](https://github.com/torrentpier/torrentpier-lts/pull/256), [\#257](https://github.com/torrentpier/torrentpier-lts/pull/257), [\#258](https://github.com/torrentpier/torrentpier-lts/pull/258), [\#259](https://github.com/torrentpier/torrentpier-lts/pull/259), [\#261](https://github.com/torrentpier/torrentpier-lts/pull/261), [\#262](https://github.com/torrentpier/torrentpier-lts/pull/262), [\#263](https://github.com/torrentpier/torrentpier-lts/pull/263), [\#264](https://github.com/torrentpier/torrentpier-lts/pull/264) ([belomaxorka](https://github.com/belomaxorka))
## [v2.1.5-2023.08-HotFix](https://github.com/torrentpier/torrentpier-lts/tree/v2.1.5-2023.08-HotFix) (2023-09-17) ## [v2.1.5-2023.08-HotFix](https://github.com/torrentpier/torrentpier-lts/tree/v2.1.5-2023.08-HotFix) (2023-09-17)
[Full Changelog](https://github.com/torrentpier/torrentpier-lts/compare/v2.1.5-2023.08...v2.1.5-2023.08-HotFix) [Full Changelog](https://github.com/torrentpier/torrentpier-lts/compare/v2.1.5-2023.08...v2.1.5-2023.08-HotFix)

View File

@ -1037,7 +1037,7 @@ else
'ROW_CLASS' => $row_class, 'ROW_CLASS' => $row_class,
'USER' => profile_url($rowset[$i]), 'USER' => profile_url($rowset[$i]),
'EMAIL' => $rowset[$i]['user_email'], 'EMAIL' => $rowset[$i]['user_email'],
'JOINDATE' => bb_date($rowset[$i]['user_regdate'], $bb_cfg['date_format']), 'JOINDATE' => bb_date($rowset[$i]['user_regdate'], $bb_cfg['reg_date_format']),
'LASTVISIT' => bb_date($rowset[$i]['user_lastvisit'], $bb_cfg['last_visit_date_format']), 'LASTVISIT' => bb_date($rowset[$i]['user_lastvisit'], $bb_cfg['last_visit_date_format']),
'POSTS' => $rowset[$i]['user_posts'], 'POSTS' => $rowset[$i]['user_posts'],
'BAN' => ( ( !isset($banned[$rowset[$i]['user_id']]) ) ? $lang['NOT_BANNED'] : $lang['BANNED'] ), 'BAN' => ( ( !isset($banned[$rowset[$i]['user_id']]) ) ? $lang['NOT_BANNED'] : $lang['BANNED'] ),

View File

@ -17,7 +17,7 @@ function generate_user_info(&$row, $date_format, $group_mod, &$from, &$posts, &$
global $lang, $images, $bb_cfg; global $lang, $images, $bb_cfg;
$from = (!empty($row['user_from'])) ? $row['user_from'] : $lang['NOSELECT']; $from = (!empty($row['user_from'])) ? $row['user_from'] : $lang['NOSELECT'];
$joined = bb_date($row['user_regdate'], $bb_cfg['date_format']); $joined = bb_date($row['user_regdate'], $bb_cfg['reg_date_format']);
$user_time = (!empty($row['user_time'])) ? bb_date($row['user_time']) : $lang['NONE']; $user_time = (!empty($row['user_time'])) ? bb_date($row['user_time']) : $lang['NONE'];
$posts = ($row['user_posts']) ? $row['user_posts'] : 0; $posts = ($row['user_posts']) ? $row['user_posts'] : 0;
$pm = ($bb_cfg['text_buttons']) ? '<a class="txtb" href="'. (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=".$row['user_id']) .'">'. $lang['SEND_PM_TXTB'] .'</a>' : '<a href="' . (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=".$row['user_id']) .'"><img src="' . $images['icon_pm'] . '" alt="' . $lang['SEND_PRIVATE_MESSAGE'] . '" title="' . $lang['SEND_PRIVATE_MESSAGE'] . '" border="0" /></a>'; $pm = ($bb_cfg['text_buttons']) ? '<a class="txtb" href="'. (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=".$row['user_id']) .'">'. $lang['SEND_PM_TXTB'] .'</a>' : '<a href="' . (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=".$row['user_id']) .'"><img src="' . $images['icon_pm'] . '" alt="' . $lang['SEND_PRIVATE_MESSAGE'] . '" title="' . $lang['SEND_PRIVATE_MESSAGE'] . '" border="0" /></a>';

View File

@ -378,7 +378,11 @@ define('CRON_ALLOWED', TRIGGERS_DIR .'cron_allowed');
define('CRON_RUNNING', TRIGGERS_DIR .'cron_running'); define('CRON_RUNNING', TRIGGERS_DIR .'cron_running');
// Date format // Date format
$bb_cfg['date_format'] = 'Y-m-d H:i'; $bb_cfg['date_format'] = 'Y-m-d'; // общий формат даты (оставлено для обратной совместимости. Если есть возможность, то используйте лучше одну из переменных ниже, исходя из целей)
$bb_cfg['current_time_date_format'] = 'd-M H:i'; // формат блока "текущее время" на сайте
$bb_cfg['reg_date_format'] = 'Y-m-d H:i'; // формат даты регистрации пользователя
$bb_cfg['last_visit_date_format'] = 'Y-m-d H:i'; // формат даты последнего визита на сайте
$bb_cfg['last_post_date_format'] = 'd-M-y H:i'; // формат даты последнего поста (на странице просмотра форума и на главной)
// Subforums // Subforums
$bb_cfg['sf_on_first_page_only'] = true; $bb_cfg['sf_on_first_page_only'] = true;
@ -451,6 +455,9 @@ $bb_cfg['pm_days_keep'] = 0; // время хранени
// Actions log // Actions log
$bb_cfg['log_days_keep'] = 365; // время хранения истории действий (0 - без ограничения) $bb_cfg['log_days_keep'] = 365; // время хранения истории действий (0 - без ограничения)
// Poll
$bb_cfg['poll_max_days'] = 180; // сколько дней с момента создания темы опрос будет активным
// Users // Users
$bb_cfg['color_nick'] = true; // Окраска ников пользователей по user_rank $bb_cfg['color_nick'] = true; // Окраска ников пользователей по user_rank
$bb_cfg['user_not_activated_days_keep'] = 7; // "not activated" == "not finished registration" $bb_cfg['user_not_activated_days_keep'] = 7; // "not activated" == "not finished registration"
@ -488,11 +495,6 @@ $bb_cfg['translate_dates'] = true; // in displaying time
$bb_cfg['use_word_censor'] = true; // использовать цензор слов $bb_cfg['use_word_censor'] = true; // использовать цензор слов
$bb_cfg['show_jumpbox'] = true; // показывать ли jumpbox $bb_cfg['show_jumpbox'] = true; // показывать ли jumpbox
$bb_cfg['current_time_date_format'] = 'd-M H:i'; // формат блока "текущее время" на сайте
$bb_cfg['last_visit_date_format'] = 'Y-m-d H:i'; // формат даты последнего визита на сайте
$bb_cfg['last_post_date_format'] = 'd-M-y H:i'; // формат даты последнего поста (на странице просмотра форума и на главной)
$bb_cfg['poll_max_days'] = 180; // сколько дней с момента создания темы опрос будет активным
$bb_cfg['allow_change'] = array( $bb_cfg['allow_change'] = array(
'language' => true, 'language' => true,
'dateformat' => true, 'dateformat' => true,

View File

@ -87,7 +87,7 @@ $template->assign_vars(array(
'USERNAME' => $profiledata['username'], 'USERNAME' => $profiledata['username'],
'PROFILE_USER_ID' => $profiledata['user_id'], 'PROFILE_USER_ID' => $profiledata['user_id'],
'PROFILE_USER' => $profile_user_id, 'PROFILE_USER' => $profile_user_id,
'USER_REGDATE' => bb_date($profiledata['user_regdate'], $bb_cfg['date_format'], false), 'USER_REGDATE' => bb_date($profiledata['user_regdate'], $bb_cfg['reg_date_format'], false),
'POSTER_RANK' => ($poster_rank) ? "<span class=\"$rank_style\">". $poster_rank ."</span>" : $lang['USER'], 'POSTER_RANK' => ($poster_rank) ? "<span class=\"$rank_style\">". $poster_rank ."</span>" : $lang['USER'],
'RANK_IMAGE' => $rank_image, 'RANK_IMAGE' => $rank_image,
'RANK_SELECT' => $rank_select, 'RANK_SELECT' => $rank_select,

View File

@ -167,7 +167,7 @@ if ($result = DB()->fetch_rowset($sql))
{ {
$user_id = $row['user_id']; $user_id = $row['user_id'];
$from = $row['user_from']; $from = $row['user_from'];
$joined = bb_date($row['user_regdate'], $bb_cfg['date_format']); $joined = bb_date($row['user_regdate'], $bb_cfg['reg_date_format']);
$posts = $row['user_posts']; $posts = $row['user_posts'];
$pm = ($bb_cfg['text_buttons']) ? '<a class="txtb" href="'. (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=$user_id") .'">'. $lang['SEND_PM_TXTB'] .'</a>' : '<a href="' . (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=$user_id") .'"><img src="' . $images['icon_pm'] . '" alt="' . $lang['SEND_PRIVATE_MESSAGE'] . '" title="' . $lang['SEND_PRIVATE_MESSAGE'] . '" border="0" /></a>'; $pm = ($bb_cfg['text_buttons']) ? '<a class="txtb" href="'. (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=$user_id") .'">'. $lang['SEND_PM_TXTB'] .'</a>' : '<a href="' . (PM_URL . "?mode=post&amp;". POST_USERS_URL ."=$user_id") .'"><img src="' . $images['icon_pm'] . '" alt="' . $lang['SEND_PRIVATE_MESSAGE'] . '" title="' . $lang['SEND_PRIVATE_MESSAGE'] . '" border="0" /></a>';
@ -240,4 +240,4 @@ $template->assign_vars(array(
'PAGE_TITLE' => $lang['MEMBERLIST'], 'PAGE_TITLE' => $lang['MEMBERLIST'],
)); ));
print_page('memberlist.tpl'); print_page('memberlist.tpl');

View File

@ -659,7 +659,7 @@ for($i = 0; $i < $total_posts; $i++)
$max_post_time = max($max_post_time, $postrow[$i]['post_time']); $max_post_time = max($max_post_time, $postrow[$i]['post_time']);
$poster_posts = ($poster_id != GUEST_UID) ? $postrow[$i]['user_posts'] : ''; $poster_posts = ($poster_id != GUEST_UID) ? $postrow[$i]['user_posts'] : '';
$poster_from = ($postrow[$i]['user_from'] && $poster_id != GUEST_UID ) ? $postrow[$i]['user_from'] : ''; $poster_from = ($postrow[$i]['user_from'] && $poster_id != GUEST_UID ) ? $postrow[$i]['user_from'] : '';
$poster_joined = ($poster_id != GUEST_UID) ? $lang['JOINED'] . ': ' . bb_date($postrow[$i]['user_regdate'], $bb_cfg['date_format']) : ''; $poster_joined = ($poster_id != GUEST_UID) ? $lang['JOINED'] . ': ' . bb_date($postrow[$i]['user_regdate'], $bb_cfg['reg_date_format']) : '';
$poster_longevity = ($poster_id != GUEST_UID) ? delta_time($postrow[$i]['user_regdate']) : ''; $poster_longevity = ($poster_id != GUEST_UID) ? delta_time($postrow[$i]['user_regdate']) : '';
$post_id = $postrow[$i]['post_id']; $post_id = $postrow[$i]['post_id'];
$mc_type = $postrow[$i]['mc_type']; $mc_type = $postrow[$i]['mc_type'];