aboutsummaryrefslogtreecommitdiffstats
path: root/core/functions.php
diff options
context:
space:
mode:
Diffstat (limited to 'core/functions.php')
-rw-r--r--core/functions.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/core/functions.php b/core/functions.php
index ad63334..7bddb5b 100644
--- a/core/functions.php
+++ b/core/functions.php
@@ -193,6 +193,30 @@ function parseEmoticons($string): string {
}
#===============================================================================
+# Get unicode emoticons with their corresponding explanation
+#===============================================================================
+function getUnicodeEmoticons(): array {
+ $Language = Application::getLanguage();
+
+ return [
+ html_entity_decode('😊') => $Language->text('emoticon_1F60A'),
+ html_entity_decode('😞') => $Language->text('emoticon_1F61E'),
+ html_entity_decode('😃') => $Language->text('emoticon_1F603'),
+ html_entity_decode('😛') => $Language->text('emoticon_1F61B'),
+ html_entity_decode('😲') => $Language->text('emoticon_1F632'),
+ html_entity_decode('😉') => $Language->text('emoticon_1F609'),
+ html_entity_decode('😢') => $Language->text('emoticon_1F622'),
+ html_entity_decode('😐') => $Language->text('emoticon_1F610'),
+ html_entity_decode('😵') => $Language->text('emoticon_1F635'),
+ html_entity_decode('😒') => $Language->text('emoticon_1F612'),
+ html_entity_decode('😎') => $Language->text('emoticon_1F60E'),
+ html_entity_decode('😟') => $Language->text('emoticon_1F61F'),
+ html_entity_decode('😂') => $Language->text('emoticon_1F602'),
+ html_entity_decode('😄') => $Language->text('emoticon_1F604'),
+ ];
+}
+
+#===============================================================================
# Wrapper function for htmlspecialchars()
#===============================================================================
function escapeHTML($string): string {