Compare commits

...

24 Commits

Author SHA1 Message Date
f9b53cb044 Allow deleting messages by name, when only PMs were sent. 2016-07-23 20:40:18 +02:00
24575374eb Use pre-calculated greyval instead of calculating it every time 2016-07-23 07:50:43 +02:00
18810a387c Delete messages based on public message limit, no buffer for private ones needed 2016-07-23 07:49:20 +02:00
8518536956 Use subqueries for less db traffic 2016-07-22 14:42:35 +02:00
0ebb5ddc82 Allow selectively deleting your own messages 2016-07-21 20:30:34 +02:00
643189d5ee Simplify ignore logic + disallow ignoring chatters with higher status 2016-07-21 09:12:07 +02:00
5c4586c04e Check permission before selectively deleting a message. 2016-07-19 23:01:33 +02:00
ba35a1c8d0 Don't hotlink schema links without protocol. 2016-07-15 17:56:41 +02:00
e8968d7712 Fix typo in CHANGELOG 2016-07-14 13:17:36 +02:00
35a2d5a524 Third attempt to fix the same bug 2016-07-12 20:43:36 +02:00
2cf52871b8 Fetch only relevant ignored data 2016-07-12 11:31:08 +02:00
309d86050b make $A and $P use same data layout 2016-07-12 11:02:52 +02:00
c8f3020f17 Yesterdays bugfix broke more than it fixed, refixed. 2016-07-10 10:38:15 +02:00
260dbdfd56 Fix bug preventing to send PMs to number-only nicknames 2016-07-09 17:52:29 +02:00
53211076a0 Making a moderator to member now sets incognito back to disabled 2016-06-13 19:55:09 +02:00
5ef5d5f701 Bugfix 2016-05-21 16:49:05 +02:00
b053e18e11 Make embed image option re-appear whith cookies disabled 2016-05-17 09:55:52 +02:00
eb13ee2d2f Completely fix link-redirection 2016-05-15 09:33:06 +02:00
dca1b81ef9 Add a lang_update.php script to auto-update language files 2016-05-11 12:46:50 +02:00
86b1de0ec8 Add setting in profile to allow offline inbox for: staff, members or everyone 2016-05-10 12:49:31 +02:00
147c511c61 Only use js if browser refresh stopped working 2016-05-10 08:16:25 +02:00
07ff78994e Remove JavaScript "load only new messages" feature, add JS auto-refresh to header instead 2016-05-07 10:37:56 +02:00
b09cb6b352 Fix parts of the offline inbox 2016-05-01 20:15:55 +02:00
e454b44f2b de-duplicate code 2016-04-30 15:29:41 +02:00
11 changed files with 352 additions and 311 deletions

View File

@ -1,3 +1,36 @@
Version 1.20.6 - Jul. 23, 2016
Simplify ignore logic + disallow ignoring chatters with higher status
Delete messages based on public message limit, no buffer for private ones needed
Allow deleting messages by name, when only PMs were sent
Version 1.20.5 - Jul. 19, 2016
Check permission before selectively deleting a message.
Version 1.20.4 - Jul. 12, 2016
Third attempt to fix the same bug
Version 1.20.3 - Jul. 10, 2016
Yesterdays bugfix broke more than it fixed, refixed.
Version 1.20.2 - Jul. 9, 2016
Fix bug preventing to send PMs to number-only nicknames
Version 1.20.1 - Jun. 13, 2016
Bugfix when logging guests out via admin section
Don't hide image embedding option in profile with cookies disabled
Making a moderator to member now sets incognito back to disabled
Version 1.20 - May 15, 2016
Add setting in profile to allow offline inbox for: staff, members or everyone
Completely fix link-redirection
Version 1.19.2 - May 7, 2016
Remove JavaScript "load only new messages" feature
Add JS auto-refresh to header instead
Version 1.19.1 - May 1, 2016
Fix parts of the offline inbox
Version 1.19 - Apr. 29, 2016 Version 1.19 - Apr. 29, 2016
Add an offline inbox for members Add an offline inbox for members
Allow deletion of member accounts in profile Allow deletion of member accounts in profile

1
README
View File

@ -60,6 +60,7 @@ When you are done, you have to edit the chat script, to include your translation
'lang_code' =>'Language name', 'lang_code' =>'Language name',
to the $L array in the load_lang() function at the bottom, similar to what I did for the German translation. to the $L array in the load_lang() function at the bottom, similar to what I did for the German translation.
Please share your translation with me, so I can add it to the official version. Please share your translation with me, so I can add it to the official version.
To update your translation, you can copy each new string to your translation file or edit the automated lang_update.php script to reflect you language and run it.
REGEX: REGEX:

View File

@ -64,6 +64,7 @@ When you are done, you have to edit the chat script, to include your translation
'lang_code' =>'Language name', 'lang_code' =>'Language name',
to the $L array in the load_lang() function at the bottom, similar to what I did for the German translation. to the $L array in the load_lang() function at the bottom, similar to what I did for the German translation.
Please share your translation with me, so I can add it to the official version. Please share your translation with me, so I can add it to the official version.
To update your translation, you can copy each new string to your translation file or edit the automated lang_update.php script to reflect you language and run it.
Regex: Regex:
------ ------

565
chat.php

File diff suppressed because it is too large Load Diff

View File

@ -254,7 +254,6 @@ $T=array(
'captchatime' => 'Captcha-Ablaufzeit (Sekunden)', 'captchatime' => 'Captcha-Ablaufzeit (Sekunden)',
'messageexpire' => 'Nachrichten-Ablaufzeit (Minuten)', 'messageexpire' => 'Nachrichten-Ablaufzeit (Minuten)',
'messagelimit' => 'Nachrichtenlimit (öffentliche)', 'messagelimit' => 'Nachrichtenlimit (öffentliche)',
'keeplimit' => 'So viele Male zusätzliche Nachrichten behalten (PMs und Mitgliederchat)',
'maxmessage' => 'Maximale Nachrichenlänge', 'maxmessage' => 'Maximale Nachrichenlänge',
'confirm' => 'Bist du sicher?', 'confirm' => 'Bist du sicher?',
'yes' => 'Ja', 'yes' => 'Ja',
@ -277,7 +276,6 @@ $T=array(
'restore' => 'Wiederherstellen', 'restore' => 'Wiederherstellen',
'settings' => 'Einstellungen', 'settings' => 'Einstellungen',
'linkfilter' => 'Linkfilter', 'linkfilter' => 'Linkfilter',
'enablejs' => 'JavaScript für besseres Nachrichtenladen erlauben',
'chatname' => 'Chatname', 'chatname' => 'Chatname',
'destroy' => 'Chat zerstören', 'destroy' => 'Chat zerstören',
'destroyed' => 'Chat erfolgreich zerstört', 'destroyed' => 'Chat erfolgreich zerstört',
@ -343,6 +341,9 @@ $T=array(
'eninbox' => 'Offline Posteingang aktivieren', 'eninbox' => 'Offline Posteingang aktivieren',
'inboxmsgs' => '%d Nachrichten im Posteingang lesen', 'inboxmsgs' => '%d Nachrichten im Posteingang lesen',
'offline' => '(offline)', 'offline' => '(offline)',
'deleteacc' => 'Konto löschen' 'deleteacc' => 'Konto löschen',
'eninall' => 'Für jeden',
'eninmem' => 'Nur für Mitglieder',
'eninstaff' => 'Nur für Moderatoren'
); );
?> ?>

View File

@ -254,7 +254,6 @@ $I=array(
'captchatime' => 'Captcha timeout (seconds)', 'captchatime' => 'Captcha timeout (seconds)',
'messageexpire' => 'Message timeout (minutes)', 'messageexpire' => 'Message timeout (minutes)',
'messagelimit' => 'Message limit (public)', 'messagelimit' => 'Message limit (public)',
'keeplimit' => 'Keep this times additional messages (PMs and Member chat)',
'maxmessage' => 'Maximal message length', 'maxmessage' => 'Maximal message length',
'confirm' => 'Are you sure?', 'confirm' => 'Are you sure?',
'yes' => 'Yes', 'yes' => 'Yes',
@ -277,7 +276,6 @@ $I=array(
'restore' => 'Restore', 'restore' => 'Restore',
'settings' => 'Settings', 'settings' => 'Settings',
'linkfilter' => 'Linkfilter', 'linkfilter' => 'Linkfilter',
'enablejs' => 'Allow JavaScript for better message loading',
'chatname' => 'Chat name', 'chatname' => 'Chat name',
'destroy' => 'Destroy chat', 'destroy' => 'Destroy chat',
'destroyed' => 'Successfully destroyed chat', 'destroyed' => 'Successfully destroyed chat',
@ -343,6 +341,9 @@ $I=array(
'eninbox' => 'Enable offline inbox', 'eninbox' => 'Enable offline inbox',
'inboxmsgs' => 'Read %d messages in your inbox', 'inboxmsgs' => 'Read %d messages in your inbox',
'offline' => '(offline)', 'offline' => '(offline)',
'deleteacc' => 'Delete account' 'deleteacc' => 'Delete account',
'eninall' => 'For everyone',
'eninmem' => 'For members only',
'eninstaff' => 'For staff only'
); );
?> ?>

View File

@ -276,7 +276,6 @@ $T=array(
'restore' => 'Restablacer copia', 'restore' => 'Restablacer copia',
'settings' => 'Configuración', 'settings' => 'Configuración',
'linkfilter' => 'Filtro de enlaces', 'linkfilter' => 'Filtro de enlaces',
'enablejs' => 'Permitir JavaScript para mejorar la carga de mensajes',
'chatname' => 'Nombre de la sala', 'chatname' => 'Nombre de la sala',
'destroy' => 'Destruir sala', 'destroy' => 'Destruir sala',
'destroyed' => 'Sala destruida satisfactoriamente', 'destroyed' => 'Sala destruida satisfactoriamente',

View File

@ -276,7 +276,6 @@ $T=array(
'restore' => 'Restaurar', 'restore' => 'Restaurar',
'settings' => 'Preferencias', 'settings' => 'Preferencias',
'linkfilter' => 'Filtro de enlaces', 'linkfilter' => 'Filtro de enlaces',
'enablejs' => 'Permitir JavaScript para mejorar la carga de mensajes',
'chatname' => 'Nombre de la sala', 'chatname' => 'Nombre de la sala',
'destroy' => 'Destruir sala', 'destroy' => 'Destruir sala',
'destroyed' => 'Sala destruida satisfactoriamente', 'destroyed' => 'Sala destruida satisfactoriamente',

View File

@ -276,7 +276,6 @@ $T=array(
'restore' => 'Récupérer', 'restore' => 'Récupérer',
'settings' => 'Paramètres', 'settings' => 'Paramètres',
'linkfilter' => 'Lien filtré', 'linkfilter' => 'Lien filtré',
'enablejs' => 'Autoriser JavaScript permet un meilleur chargement des messages ',
'chatname' => 'Nom du chat', 'chatname' => 'Nom du chat',
'destroy' => 'Destruction du chat', 'destroy' => 'Destruction du chat',
'destroyed' => 'Chat supprimé', 'destroyed' => 'Chat supprimé',

View File

@ -276,7 +276,6 @@ $T=array(
'restore' => 'Pulihkan', 'restore' => 'Pulihkan',
'settings' => 'Pengaturan', 'settings' => 'Pengaturan',
'linkfilter' => 'penyaring-tautan', 'linkfilter' => 'penyaring-tautan',
'enablejs' => 'Izinkan javascript agar pemuatan pesan lebih baik',
'chatname' => 'Nama obrolan', 'chatname' => 'Nama obrolan',
'destroy' => 'Musnahkan obrolan', 'destroy' => 'Musnahkan obrolan',
'destroyed' => 'Berhasil memusnahkan obrolan', 'destroyed' => 'Berhasil memusnahkan obrolan',

45
lang_update.php Normal file
View File

@ -0,0 +1,45 @@
<?php
$native = 'Deutsch'; // Native lanugae name
$english = 'German'; // Enlish language name
$code = 'de'; // Language code
ob_start();
echo "<?php
/*
* LE CHAT-PHP - a PHP Chat based on LE CHAT - $english translation
*
* Copyright (C) 2015-2016 Daniel Winzen <d@winzen4.de>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
//Native language name: $native
\$T=array(
";
if(file_exists("lang_$code.php")){
include("lang_$code.php");
}
include('lang_en.php');
foreach($T as $id=>$value){
if(isSet($I[$id])){
$I[$id]=$value;
}
}
foreach($I as $id=>$value){
echo "\t'$id' => '".str_replace("'", "\'", $value)."',\n";
}
echo ");\n?>\n";
$file=ob_get_clean();
file_put_contents("lang_$code.php", $file);
?>