Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
6dd7d425c7 | |||
bb4ca51db8 | |||
92643bad03 | |||
be34272e1b | |||
e6265ba296 | |||
8bf25230f2 | |||
0fa1279764 | |||
cd0e2ec19c |
23
CHANGELOG
Normal file
23
CHANGELOG
Normal file
@ -0,0 +1,23 @@
|
||||
Version 1.6 - Apr. 26, 2015
|
||||
Added option to only allow guests with a global password
|
||||
|
||||
Version 1.5 - Apr. 20, 2015
|
||||
Added incognito mode
|
||||
|
||||
Version 1.4 - Apr. 10, 2015
|
||||
Various changes and additions
|
||||
|
||||
Version 1.3 - Apr. 4, 2015
|
||||
Bugfixes on logout and kicking
|
||||
|
||||
Version 1.2 - Apr. 2, 2015
|
||||
Include letters when generating captchas not only numbers
|
||||
Moved rules to database to make changes more easily in the setup
|
||||
|
||||
Version 1.1 - Apr. 2, 2015
|
||||
Some simplifications
|
||||
Added ignore feature
|
||||
|
||||
Version 1.0 - Mar. 31, 2015
|
||||
Initial release
|
||||
|
16
README
16
README
@ -18,7 +18,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
GENERAL INFORMATION:
|
||||
|
||||
This is a PHP Chat based on LE CHAT v.1.14 . An up-to-date copy of this script can be downloaded at http://github.com/DanWin/le-chat-php
|
||||
This is a PHP Chat based on LE CHAT v.1.14 . An up-to-date copy of this script can be downloaded at https://github.com/DanWin/le-chat-php
|
||||
The original perl LE CHAT script by Lucky Eddie can be downloaded at http://4fvfamdpoulu2nms.onion/lechat/ or via a tor2web proxy like https://4fvfamdpoulu2nms.tor2web.blutmagie.de/lechat/ if you don't have TOR installed.
|
||||
If you add your own cool features or have a feature request, please tell me and I will add them, if I like them.
|
||||
Please also let me know about any bugs you find in the code, so I can fix them.
|
||||
@ -60,6 +60,7 @@ Then copy the script to your web-server directory and call the script in your br
|
||||
http://(server)/(script-name).php?action=setup
|
||||
Now you can create the Superadmin account. With this account you can administer the chat and add new members and set the guest access.
|
||||
As soon as you are done with the setup, all necessary database tables will be created and the chat can be used.
|
||||
Note: If you updated the script, please visit http://(server)/(script-name).php?action=setup again, to make sure, that any database changes are applied and no errors occure.
|
||||
|
||||
TRANSLATING:
|
||||
|
||||
@ -71,6 +72,19 @@ When you are done, you have to edit the chat script, to include your 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.
|
||||
|
||||
REGEX:
|
||||
|
||||
Yes, the chat supports regular expression filtering of messages. As regex tends to be difficult for most people, I decided to give it an extra section here.
|
||||
Regex is very powerful and can be used to filter messages that contain certain expressions and replace them with something else.
|
||||
It can be used e.g. to turn BB Code into html, so it is possible to use BB Code in the chat to format messages.
|
||||
To do this, use this Regex-Match '\[(u|b)\](.*?)\[\/\1\]' and this Regex-Replace '<$1>$2</$1>' and your text will be '[b]bold[/b]' or '[u]underlined[/u]'.
|
||||
You can also use smilies by using this Regex-Match '(?-i::(cry|eek|lol|sad|smile|surprised|wink):)' and this Regex-Replace '<img src="/pictures/$1.gif" alt=":$1:">'
|
||||
And now if you enter ':smile:' an image with the smiley will be loaded from your server at '/pictures/smile.gif'.
|
||||
The following should be escaped by putting '\' in front of it, if you are trying to match one of these characters '/ \ ^ . $ | ( ) [ ] * + ? { } ,'.
|
||||
I used '/' as delimiter, so you will have to escape that, too. The only options I used is 'i' to make the regex case insensitive.
|
||||
If you want to test your regex, before applying you can use this site and enter your Regex and Replacement there and click on preg_replace: http://www.phpliveregex.com/
|
||||
If you never used regex before, check out this starting guide to begin with regular expressions: http://docs.activestate.com/komodo/4.4/regex-intro.html
|
||||
|
||||
LIVE DEMO:
|
||||
|
||||
If you want to see the script in action, you can visit my TOR hidden site http://tt3j2x4k5ycaa5zt.onion/chat.php or via a tor2web proxy like http://tt3j2x4k5ycaa5zt.tor2web.blutmagie.de/chat.php if you don't have TOR installed.
|
||||
|
17
README.md
17
README.md
@ -1,7 +1,7 @@
|
||||
General Information:
|
||||
--------------------
|
||||
|
||||
This is a PHP Chat based on LE CHAT v.1.14 . An up-to-date copy of this script can be downloaded at http://github.com/DanWin/le-chat-php
|
||||
This is a PHP Chat based on LE CHAT v.1.14 . An up-to-date copy of this script can be downloaded at https://github.com/DanWin/le-chat-php
|
||||
The original perl LE CHAT script by Lucky Eddie can be downloaded at [his site](http://4fvfamdpoulu2nms.onion/lechat/) or via a tor2web proxy like [this one](https://4fvfamdpoulu2nms.tor2web.blutmagie.de/lechat/) if you don't have TOR installed.
|
||||
If you add your own cool features or have a feature request, please tell me and I will add them, if I like them.
|
||||
Please also let me know about any bugs you find in the code, so I can fix them.
|
||||
@ -45,6 +45,7 @@ Then copy the script to your web-server directory and call the script in your br
|
||||
http://(server)/(script-name).php?action=setup
|
||||
Now you can create the Superadmin account. With this account you can administer the chat and add new members and set the guest access.
|
||||
As soon as you are done with the setup, all necessary database tables will be created and the chat can be used.
|
||||
Note: If you updated the script, please visit http://(server)/(script-name).php?action=setup again, to make sure, that any database changes are applied and no errors occure.
|
||||
|
||||
Translating:
|
||||
------------
|
||||
@ -57,6 +58,20 @@ When you are done, you have to edit the chat script, to include your 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.
|
||||
|
||||
Regex:
|
||||
------
|
||||
|
||||
Yes, the chat supports regular expression filtering of messages. As regex tends to be difficult for most people, I decided to give it an extra section here.
|
||||
Regex is very powerful and can be used to filter messages that contain certain expressions and replace them with something else.
|
||||
It can be used e.g. to turn BB Code into html, so it is possible to use BB Code in the chat to format messages.
|
||||
To do this, use this Regex-Match '\[(u|b)\](.*?)\[\/\1\]' and this Regex-Replace '<$1>$2</$1>' and your text will be '[b]bold[/b]' or '[u]underlined[/u]'.
|
||||
You can also use smilies by using this Regex-Match '(?-i::(cry|eek|lol|sad|smile|surprised|wink):)' and this Regex-Replace '<img src="/pictures/$1.gif" alt=":$1:">'
|
||||
And now if you enter ':smile:' an image with the smiley will be loaded from your server at '/pictures/smile.gif'.
|
||||
The following should be escaped by putting '\' in front of it, if you are trying to match one of these characters '/ \ ^ . $ | ( ) [ ] * + ? { } ,'.
|
||||
I used '/' as delimiter, so you will have to escape that, too. The only options I used is 'i' to make the regex case insensitive.
|
||||
If you want to test your regex, before applying you can use [this site](http://www.phpliveregex.com/) and enter your Regex and Replacement there and click on preg_replace.
|
||||
If you never used regex before, check out [this starting guide](http://docs.activestate.com/komodo/4.4/regex-intro.html) to begin with regular expressions.
|
||||
|
||||
Live demo:
|
||||
----------
|
||||
|
||||
|
14
lang_de.php
14
lang_de.php
@ -20,12 +20,12 @@
|
||||
|
||||
$I=array(
|
||||
'nodb' => 'Keine Verbindung zur Datenbank!',
|
||||
'nodsetupb' => 'Keine Verbindung zur Datenbank, bitte erstelle eine Datenbank und bearbeite das Skript, um die korrekte Datenbank mit angegebenem Benutzernamen und Passwort zu benutzen.',
|
||||
'nodbsetup' => 'Keine Verbindung zur Datenbank, bitte erstelle eine Datenbank und bearbeite das Skript, um die korrekte Datenbank mit angegebenem Benutzernamen und Passwort zu benutzen.',
|
||||
'changelang' => 'Sprache ändern:',
|
||||
'expire' => 'Ungültige/abgelaufene Sitzung',
|
||||
'kicked' => 'Rausgeschmissen!',
|
||||
'invalnick' => 'Ungültiger Nickname (Maximal %d Zeichen, keine Sonderzeichen erlaubt)',
|
||||
'invalpass' => 'Falsches Passwort!',
|
||||
'invalpass' => 'Ungültiges Passwort (Mindestens %d Zeichen)',
|
||||
'noconfirm' => 'Passwordbestätigung stimmt nicht überein!',
|
||||
'incorregex' => 'Ungültiger regulärer Ausdruck!',
|
||||
'bottom' => 'Unten',
|
||||
@ -42,8 +42,7 @@ $I=array(
|
||||
'initdbexist' => 'Datenbanktabellen existieren bereits! Um vortzufahren, musst du diese Tabellen zuerst manuell löschen.',
|
||||
'initsuexist' => 'Ein Superadmin existiert bereits!',
|
||||
'initgosetup' => 'Zur Einrichtungsseite gehen',
|
||||
'dbupdate' => 'Datenbank aktualisieren',
|
||||
'update' => 'Aktualisieren',
|
||||
'dbupdate' => 'Datenbank erfolgreich aktualisiert!',
|
||||
'sysmessages' => 'Systemnachrichten',
|
||||
'msgenter' => 'Eintritt',
|
||||
'msgexit' => 'Verlassen',
|
||||
@ -55,6 +54,7 @@ $I=array(
|
||||
'msgclean' => 'Raum geleert',
|
||||
'nick' => 'Nickname:',
|
||||
'pass' => 'Passwort:',
|
||||
'globalloginpass' => 'Globales Passwort:',
|
||||
'login' => 'Anmelden',
|
||||
'admfunc' => 'Administrative Funktionen',
|
||||
'allguests' => 'Alle Gäste',
|
||||
@ -75,6 +75,7 @@ $I=array(
|
||||
'guestallow' => 'Erlauben',
|
||||
'guestwait' => 'Mit Warteraum erlauben',
|
||||
'adminallow' => 'Moderator-Erlaubnis benötigen',
|
||||
'globalpass' => 'Globales Passwort',
|
||||
'guestdisallow' => 'Verweigern',
|
||||
'addsuguest' => 'Anwerber hinzufügen',
|
||||
'register' => 'Registrieren',
|
||||
@ -131,6 +132,8 @@ $I=array(
|
||||
'helpmod' => 'Moderatoren: Achte auf den Admin-Knof unten. Er bringt eine Seite auf, auf der du Nachrichten löschen kannst, Teilnehmer rausschmeißen kannst, alle aktive Sitzungen anzeigen lassen kannst und den Gastzugriff deaktivieren kannst, falls dies nötig sein sollte.',
|
||||
'helpadm' => 'Admins: Du wirst zusätzlich in der Lage sein Gäste zu registrieren, Mitglieder zu verwalten und neue Nicknanem zu registrieren, ohne dass sie im Raum sind.',
|
||||
'profile' => 'Dein Profil',
|
||||
'ignore' => 'Ignorieren',
|
||||
'unignore' => 'Nicht mehr ignorieren',
|
||||
'refreshrate' => 'Aktualisierungsrate (20-150 Sekunden)',
|
||||
'fontcolour' => 'Schriftfarbe',
|
||||
'viewexample' => 'Beispiele anzeigen',
|
||||
@ -142,6 +145,7 @@ $I=array(
|
||||
'fontexample' => 'Beispiel für deine gewählte Schrift',
|
||||
'timestamps' => 'Zeitstempel anzeigen',
|
||||
'embed' => 'Bilder/Videos einbetten',
|
||||
'incognito' => 'Inkognito Modus',
|
||||
'pbsize' => 'Postboxgröße',
|
||||
'nbsize' => 'Notizboxgröße',
|
||||
'width' => 'Breite:',
|
||||
@ -188,7 +192,7 @@ $I=array(
|
||||
'cantchgstat' => 'Der Status von %s kann nicht geändert werden.',
|
||||
'succdel' => '%s wurde erfolgriech aus der Datenbank gelöscht.',
|
||||
'succchg' => 'Status of %s successfully changed.',
|
||||
'wrongpass' => 'Passwort ist falsch.',
|
||||
'wrongpass' => 'Falsches Passwort!',
|
||||
'succprofile' => 'Dein Profil wurde erfolgreich gespeichert.',
|
||||
'backtologin' => 'Zurück zur Anmeldeseite.',
|
||||
'backtochat' => 'Zurück zum Chat.',
|
||||
|
14
lang_en.php
14
lang_en.php
@ -21,12 +21,12 @@
|
||||
//Language: English
|
||||
$I=array(
|
||||
'nodb' => 'No Connection to Database!',
|
||||
'nodsetupb' => 'No Connection to Database, please create a database and edit the script to use the correct database with given username and password!',
|
||||
'nodbsetup' => 'No Connection to Database, please create a database and edit the script to use the correct database with given username and password!',
|
||||
'changelang' => 'Change language:',
|
||||
'expire' => 'Invalid/expired session',
|
||||
'kicked' => 'Kicked!',
|
||||
'invalnick' => 'Invalid nickname (%d characters maximum, no special characters allowed)',
|
||||
'invalpass' => 'Invalid password!',
|
||||
'invalpass' => 'Invalid password (At least %d characters)',
|
||||
'noconfirm' => 'Password confirmation does not match!',
|
||||
'incorregex' => 'Incorrect regular expression!',
|
||||
'bottom' => 'Bottom',
|
||||
@ -45,9 +45,9 @@ $I=array(
|
||||
'initgosetup' => 'Go to the Setup-Page',
|
||||
'nick' => 'Nickname:',
|
||||
'pass' => 'Password:',
|
||||
'globalloginpass' => 'Global Password:',
|
||||
'login' => 'Login',
|
||||
'dbupdate' => 'Update database',
|
||||
'update' => 'Update',
|
||||
'dbupdate' => 'Database successfully updated!',
|
||||
'sysmessages' => 'System messages',
|
||||
'msgenter' => 'Entrance',
|
||||
'msgexit' => 'Leaving',
|
||||
@ -76,6 +76,7 @@ $I=array(
|
||||
'guestallow' => 'Allow',
|
||||
'guestwait' => 'Allow with waitingroom',
|
||||
'adminallow' => 'Require moderator approval',
|
||||
'globalpass' => 'Global Password',
|
||||
'guestdisallow' => 'Disallow',
|
||||
'addsuguest' => 'Add applicant',
|
||||
'register' => 'Register',
|
||||
@ -132,6 +133,8 @@ $I=array(
|
||||
'helpmod' => 'Moderators: Notice the Admin-button at the bottom. It\'ll bring up a page where you can clean the room, kick chatters, view all active sessions and disable guest access completely if needed.',
|
||||
'helpadm' => 'Admins: You\'ll be furthermore able to register guests, edit members and register new nicks without them beeing in the room.',
|
||||
'profile' => 'Your Profile',
|
||||
'ignore' => 'Ignore',
|
||||
'unignore' => 'Don\'t ignore anymore',
|
||||
'refreshrate' => 'Refresh rate (20-150 seconds)',
|
||||
'fontcolour' => 'Font colour',
|
||||
'viewexample' => 'View examples',
|
||||
@ -143,6 +146,7 @@ $I=array(
|
||||
'fontexample' => 'Example for your chosen font',
|
||||
'timestamps' => 'Show Timestamps',
|
||||
'embed' => 'Embed images/videos',
|
||||
'incognito' => 'Incognito mode',
|
||||
'pbsize' => 'Post box size',
|
||||
'nbsize' => 'Notes box size',
|
||||
'width' => 'Width:',
|
||||
@ -189,7 +193,7 @@ $I=array(
|
||||
'cantchgstat' => 'Can\'t change status of %s',
|
||||
'succdel' => '%s successfully deleted from database.',
|
||||
'succchg' => 'Status of %s successfully changed.',
|
||||
'wrongpass' => 'Password is wrong.',
|
||||
'wrongpass' => 'Wrong Password!',
|
||||
'succprofile' => 'Your profile has successfully been saved.',
|
||||
'backtologin' => 'Back to the login page.',
|
||||
'backtochat' => 'Back to the chat.',
|
||||
|
Reference in New Issue
Block a user