aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-03-19 03:18:39 -0700
committerfriendica <info@friendica.com>2012-03-19 03:18:39 -0700
commit2349852b4abd1638624b541f173f51d1fb1ea011 (patch)
tree817dad1559f2b40d8bd082e86af1d8be83ba6ed6
parentcf2edb5b9ad5f9bad1fa94ad577f1ab8a664e8e6 (diff)
downloadvolse-hubzilla-2349852b4abd1638624b541f173f51d1fb1ea011.tar.gz
volse-hubzilla-2349852b4abd1638624b541f173f51d1fb1ea011.tar.bz2
volse-hubzilla-2349852b4abd1638624b541f173f51d1fb1ea011.zip
support "no_smilies"
-rw-r--r--include/text.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/text.php b/include/text.php
index 89acbf9fa..a0ff1600e 100644
--- a/include/text.php
+++ b/include/text.php
@@ -694,8 +694,13 @@ function linkify($s) {
if(! function_exists('smilies')) {
function smilies($s, $sample = false) {
+
$a = get_app();
+ if(intval(get_config('system','no_smilies'))
+ || (local_user() && intval(get_pconfig(local_user(),'system','no_smilies'))))
+ return $s;
+
$s = preg_replace_callback('/<pre>(.*?)<\/pre>/ism','smile_encode',$s);
$s = preg_replace_callback('/<code>(.*?)<\/code>/ism','smile_encode',$s);