]> git.mxchange.org Git - friendica.git/commitdiff
support "no_smilies"
authorfriendica <info@friendica.com>
Mon, 19 Mar 2012 10:18:39 +0000 (03:18 -0700)
committerfriendica <info@friendica.com>
Mon, 19 Mar 2012 10:18:39 +0000 (03:18 -0700)
include/text.php

index 89acbf9fabc3d2acc4376f2100c0a53f0c6cd1da..a0ff1600ed4bcb4a9c961e50c83b4324e831c55b 100644 (file)
@@ -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);