mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-14 18:48:21 -07:00
Minor improvements (#920)
This commit is contained in:
parent
6a007023da
commit
82e5829426
4 changed files with 8 additions and 8 deletions
|
@ -559,12 +559,12 @@ $bb_cfg['attach'] = [
|
|||
'max_size' => 5 * 1024 * 1024, // максимальный размер файла в байтах
|
||||
];
|
||||
|
||||
$bb_cfg['tor_forums_allowed_ext'] = ['torrent', 'zip', 'rar']; // для разделов с раздачами
|
||||
$bb_cfg['gen_forums_allowed_ext'] = ['zip', 'rar']; // для обычных разделов
|
||||
$bb_cfg['tor_forums_allowed_ext'] = ['torrent', 'zip', 'rar']; // TODO: для разделов с раздачами
|
||||
$bb_cfg['gen_forums_allowed_ext'] = ['zip', 'rar']; // TODO: для обычных разделов
|
||||
|
||||
// Avatars
|
||||
$bb_cfg['avatars'] = [
|
||||
'allowed_ext' => ['gif', 'jpg', 'jpeg', 'png'], // разрешенные форматы файлов
|
||||
'allowed_ext' => ['gif', 'jpg', 'jpeg', 'png', 'webp', 'bmp'], // разрешенные форматы файлов
|
||||
'bot_avatar' => '/gallery/bot.gif', // аватара бота
|
||||
'max_size' => 100 * 1024, // размер аватары в байтах
|
||||
'max_height' => 100, // высота аватара в px
|
||||
|
@ -577,7 +577,7 @@ $bb_cfg['avatars'] = [
|
|||
|
||||
// Group avatars
|
||||
$bb_cfg['group_avatars'] = [
|
||||
'allowed_ext' => ['gif', 'jpg', 'jpeg', 'png'], // разрешенные форматы файлов
|
||||
'allowed_ext' => ['gif', 'jpg', 'jpeg', 'png', 'webp', 'bmp'], // разрешенные форматы файлов
|
||||
'max_size' => 300 * 1024, // размер аватары в байтах
|
||||
'max_height' => 300, // высота аватара в px
|
||||
'max_width' => 300, // ширина аватара в px
|
||||
|
|
|
@ -547,7 +547,7 @@ switch ($mode) {
|
|||
$poster_id = $postrow[$i]['poster_id'];
|
||||
$poster = $postrow[$i]['username'];
|
||||
|
||||
$post_date = bb_date($postrow[$i]['post_time']);
|
||||
$post_date = bb_date($postrow[$i]['post_time'], $bb_cfg['post_date_format']);
|
||||
|
||||
$message = $postrow[$i]['post_text'];
|
||||
|
||||
|
|
|
@ -76,7 +76,7 @@ class BBCode
|
|||
private function init_replacements(): void
|
||||
{
|
||||
$tpl = $this->tpl;
|
||||
$img_exp = '(https?:)?//[^\s\?&;=\#\"<>]+?\.(jpg|jpeg|gif|png)([a-z0-9/?&%;][^\[\]]*)?';
|
||||
$img_exp = '(https?:)?//[^\s\?&;=\#\"<>]+?\.(jpg|jpeg|gif|png|bmp)([a-z0-9/?&%;][^\[\]]*)?';
|
||||
$email_exp = '[a-z0-9&\-_.]+?@[\w\-]+\.([\w\-\.]+\.)?[\w]+';
|
||||
|
||||
$this->preg = [
|
||||
|
|
|
@ -374,8 +374,8 @@ var TPL = {
|
|||
reg: {
|
||||
num : /^\d+$/,
|
||||
URL : /^https?:\/\/[\w\#$%&~/.\-;:=?@\[\]+]+$/i,
|
||||
img : /^https?:\/\/[^\s\?&;:=\#\"<>]+\.(jpg|jpeg|gif|png)$/i,
|
||||
img_tag : /(https?:\/\/[^\s\?&;:=\#\"<>]+\.(jpg|jpeg|gif|png)(?!\[|\]|\.))/ig
|
||||
img : /^https?:\/\/[^\s\?&;:=\#\"<>]+\.(jpg|jpeg|gif|png|bmp)$/i,
|
||||
img_tag : /(https?:\/\/[^\s\?&;:=\#\"<>]+\.(jpg|jpeg|gif|png|bmp)(?!\[|\]|\.))/ig
|
||||
},
|
||||
|
||||
// построение сообщения на основе данных из формы
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue