Minor improvements (#1525)

* Minor improvements

* Update posting_tpl.tpl

* Update CHANGELOG.md

* Updated

* Update clean_pm.php

* Update mysql.sql

* Update mysql.sql

* Update mysql.sql

* Update mysql.sql

* Update mysql.sql
This commit is contained in:
Roman Kelesidis 2024-06-28 12:38:43 +07:00 committed by GitHub
commit 3488c9cc28
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 33 additions and 22 deletions

View file

@ -14,7 +14,7 @@
- Some security improvements 🔑 [\#1503](https://github.com/torrentpier/torrentpier/pull/1503), [\#1505](https://github.com/torrentpier/torrentpier/pull/1505) ([belomaxorka](https://github.com/belomaxorka))
- Some improvements for integrity checker [\#1501](https://github.com/torrentpier/torrentpier/pull/1501) ([belomaxorka](https://github.com/belomaxorka))
- Hide vote button in topic for guests [\#1507](https://github.com/torrentpier/torrentpier/pull/1507) ([belomaxorka](https://github.com/belomaxorka))
- Minor improvements [\#1502](https://github.com/torrentpier/torrentpier/pull/1502), [\#1506](https://github.com/torrentpier/torrentpier/pull/1506), [\#1509](https://github.com/torrentpier/torrentpier/pull/1509), [\#1511](https://github.com/torrentpier/torrentpier/pull/1511), [\#1515](https://github.com/torrentpier/torrentpier/pull/1515), [\#1516](https://github.com/torrentpier/torrentpier/pull/1516), [\#1517](https://github.com/torrentpier/torrentpier/pull/1517), [\#1519](https://github.com/torrentpier/torrentpier/pull/1519), [\#1523](https://github.com/torrentpier/torrentpier/pull/1523) ([belomaxorka](https://github.com/belomaxorka))
- Minor improvements [\#1502](https://github.com/torrentpier/torrentpier/pull/1502), [\#1506](https://github.com/torrentpier/torrentpier/pull/1506), [\#1509](https://github.com/torrentpier/torrentpier/pull/1509), [\#1511](https://github.com/torrentpier/torrentpier/pull/1511), [\#1515](https://github.com/torrentpier/torrentpier/pull/1515), [\#1516](https://github.com/torrentpier/torrentpier/pull/1516), [\#1517](https://github.com/torrentpier/torrentpier/pull/1517), [\#1519](https://github.com/torrentpier/torrentpier/pull/1519), [\#1523](https://github.com/torrentpier/torrentpier/pull/1523), [\#1525](https://github.com/torrentpier/torrentpier/pull/1525) ([belomaxorka](https://github.com/belomaxorka))
- New Crowdin updates [\#1504](https://github.com/torrentpier/torrentpier/pull/1504), [\#1513](https://github.com/torrentpier/torrentpier/pull/1513) ([Exileum](https://github.com/Exileum))
## [v2.4.3](https://github.com/torrentpier/torrentpier/tree/v2.4.3) (2024-06-09)

View file

@ -26,7 +26,7 @@ $cfg = [];
* All config names with default values
*/
$default_cfg_str = array(
'bt_announce_url' => 'http://demo.torrentpier.com/bt/',
'bt_announce_url' => 'https://torrentpier.duckdns.org/bt/',
);
$default_cfg_bool = array(

View file

@ -997,7 +997,7 @@ CREATE TABLE IF NOT EXISTS `bb_posts_text`
-- ----------------------------
INSERT INTO `bb_posts_text`
VALUES ('1',
'Thank you for installing the new — TorrentPier Cattle!\n\nWhat to do next? First of all configure your site in the administration panel (link in the bottom).\n\nChange main options: site description, number of messages per topic, time zone, language by default, seed-bonus options, birthdays etc... Create a couple of forums, delete or change this one. Change settings of categories to allow registration of torrents, change announcer url. If you will have questions or want additional modifications of the engine, [url=https://torrentpier.com/]visit our forum[/url] (you can use english, we will try to help in any case).\n\nIf you want to help with the translations: [url=https://crowdin.com/project/torrentpier]Crowdin[/url].\n\nWe are sure that you will be able to create the best tracker available.\nGood luck!');
'Thank you for installing the new — TorrentPier Cattle!\n\nWhat to do next? First of all configure your site in the administration panel (link in the bottom).\n\nChange main options: site description, number of messages per topic, time zone, language by default, seed-bonus options, birthdays etc... Create a couple of forums, delete or change this one. Change settings of categories to allow registration of torrents, change announcer url. If you will have questions or want additional modifications of the engine, [url=https://torrentpier.com/]visit our forum[/url] (you can use english, we will try to help in any case).\n\nIf you want to help with the translations: [url=https://crowdin.com/project/torrentpier]Crowdin[/url].\n\nOur GitHub organization: [url=https://github.com/torrentpier]https://github.com/torrentpier[/url].\nOur SourceForge repository: [url=https://sourceforge.net/projects/torrentpier-engine]https://sourceforge.net/projects/torrentpier-engine[/url].\nOur demo website: [url=https://torrentpier.duckdns.org]https://torrentpier.duckdns.org[/url].\n\nWe are sure that you will be able to create the best tracker available!\nGood luck! 😉');
-- ----------------------------
-- Table structure for `bb_privmsgs`

View file

@ -109,15 +109,6 @@ switch ($field) {
$this->response['new_value'] = htmlCHR($value);
break;
case 'user_regdate':
case 'user_lastvisit':
$tz = TIMENOW + (3600 * $bb_cfg['board_timezone']);
if (($value = strtotime($value, $tz)) < $bb_cfg['board_startdate'] or $value > TIMENOW) {
$this->ajax_die($lang['INVALID_DATE'] . $this->request['value']);
}
$this->response['new_value'] = bb_date($value, 'Y-m-d H:i', false);
break;
case 'u_up_total':
case 'u_down_total':
case 'u_up_release':

View file

@ -14,5 +14,27 @@ if (!defined('BB_ROOT')) {
$pm_days_keep = (int)$bb_cfg['pm_days_keep'];
if ($pm_days_keep !== 0) {
DB()->query("DELETE FROM " . BB_PRIVMSGS . " WHERE privmsgs_date < " . (TIMENOW - 86400 * $pm_days_keep));
$per_cycle = 20000;
$row = DB()->fetch_row("SELECT MIN(privmsgs_id) AS start_id, MAX(privmsgs_id) AS finish_id FROM " . BB_PRIVMSGS);
$start_id = (int)$row['start_id'];
$finish_id = (int)$row['finish_id'];
while (true) {
set_time_limit(600);
$end_id = $start_id + $per_cycle - 1;
DB()->query("
DELETE pm, pmt
FROM " . BB_PRIVMSGS . " pm
LEFT JOIN " . BB_PRIVMSGS_TEXT . " pmt ON(pmt.privmsgs_text_id = pm.privmsgs_id)
WHERE pm.privmsgs_id BETWEEN $start_id AND $end_id
AND pm.privmsgs_date < " . (TIMENOW - 86400 * $pm_days_keep) . "
");
if ($end_id > $finish_id) {
break;
}
$start_id += $per_cycle;
}
}

View file

@ -17,7 +17,7 @@ $announce_urls = $additional_announce_urls = [];
// Allowed Announcer URLs
// ------------------------------------------------------------------------------------------------------------------------------
// Examples:
// $announce_urls[] = 'http://demo.torrentpier.com/bt/announce.php';
// $announce_urls[] = 'https://torrentpier.duckdns.org/bt/announce.php';
// $announce_urls[] = 'http://tracker.openbittorrent.com:80/announce';
// $announce_urls[] = 'udp://tracker.openbittorrent.com:6969/announce';
// ------------------------------------------------------------------------------------------------------------------------------

View file

@ -72,8 +72,6 @@
<var class="ajax-params">{action: "edit_user_profile", id: "username"}</var>
<var class="ajax-params">{action: "edit_user_profile", id: "user_email"}</var>
<var class="ajax-params">{action: "edit_user_profile", id: "user_regdate"}</var>
<var class="ajax-params">{action: "edit_user_profile", id: "user_lastvisit"}</var>
<var class="ajax-params">{action: "edit_user_profile", id: "user_website"}</var>
<var class="ajax-params">{action: "edit_user_profile", id: "user_occ"}</var>
<var class="ajax-params">{action: "edit_user_profile", id: "user_interests"}</var>
@ -321,8 +319,8 @@ ajax.callback.index_data = function(data) {
<!-- ENDIF -->
<tr>
<th>{L_JOINED}:</th>
<td id="user_regdate">
<span class="editable bold">{USER_REGDATE}</span>
<td>
<b>{USER_REGDATE}</b>
<!-- IF IS_ADMIN -->
[ <a href="#admin" class="adm menu-root menu-alt1">{L_MANAGE_USER}</a> ]
<div class="menu-sub row1 border bw_TRBL" id="admin">
@ -357,8 +355,8 @@ ajax.callback.index_data = function(data) {
</tr>
<tr>
<th>{L_LAST_VISITED}:</th>
<td id="user_lastvisit">
<span class="editable bold">{LAST_VISIT_TIME}</span>
<td>
<b>{LAST_VISIT_TIME}</b>
</td>
</tr>

View file

@ -119,8 +119,8 @@ var TPL = {
// значения для автозаполнителя формы. если не определено, то заполняется названием
year : 2011,
poster : 'https://demo.torrentpier.com/styles/images/logo/logo.png',
screenshots : 'http://img462.imageshack.us/img462/8360/snapshot20070911141251ee8.png\n[img]http://img513.imageshack.us/img513/7226/snapshot20070911141324ey9.png[/img]\nhttp://img513.imageshack.us/img513/2809/snapshot20070911141335tt2.png\n[img]http://img211.imageshack.us/img211/2936/snapshot20070911141603ew2.png[/img]',
poster : 'https://torrentpier.duckdns.org/styles/images/logo/logo.png',
screenshots : '[img]https://torrentpier.duckdns.org/styles/images/logo/logo.png[/img]',
// dummy
dummy : ''