diff options
author | Guy Brand <gb@unistra.fr> | 2010-10-03 15:51:21 +0200 |
---|---|---|
committer | Guy Brand <gb@unistra.fr> | 2010-10-03 15:55:41 +0200 |
commit | 060ab504d26b1044e946e7674201fa54f8ffb184 (patch) | |
tree | 581df385edeed36a22252ffe444e18f39478bf6e | |
parent | 05fea6befaf95c4615538cd6ebd127e83712c9c9 (diff) | |
download | rpg-060ab504d26b1044e946e7674201fa54f8ffb184.tar.gz rpg-060ab504d26b1044e946e7674201fa54f8ffb184.tar.bz2 |
Truncate wiki name in sent mail (FS#2021)
-rw-r--r-- | inc/common.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/inc/common.php b/inc/common.php index 390b038a5..6af7f49de 100644 --- a/inc/common.php +++ b/inc/common.php @@ -1128,7 +1128,11 @@ function notify($id,$who,$rev='',$summary='',$minor=false,$replace=array()){ $diff = rawWiki($id); } $text = str_replace('@DIFF@',$diff,$text); - $subject = '['.$conf['title'].'] '.$subject; + if(utf8_strlen($conf['title']) < 20) { + $subject = '['.$conf['title'].'] '.$subject; + }else{ + $subject = '['.utf8_substr($conf['title'], 0, 20).'...] '.$subject; + } $from = $conf['mailfrom']; $from = str_replace('@USER@',$_SERVER['REMOTE_USER'],$from); |