notification_add($touid, $type, $note, $notevars = array(), $system = 0)
$touid : 发送给谁?
$type : 方式? 常用的是post
$note : 可以自己编辑内容
$notevars = 一些内容参数
$system = 默认情况下为0
将下列代码加入到souse/class/module/module_forum_thread.php文件第139行即可
if($this->param['isgroup']==1){ $bt=$this->param['subject']; $querys = DB::fetch_all('select * from pre_forum_groupuser where fid='.$this->forum['fid']); foreach($querys as $arr){ notification_add($arr['uid'], 'system', $author.'发表了:'.$bt, array('from_id' => 0, 'from_idtype' => 'sendnotice'), 1); } }
实现效果:群组内任意一成员在群组里面发帖子,群组所有成员就会收到系统提醒,并且提示有系统提醒。
author:超越 有问题请加群