DISCUZ Change the group posting system to remind members notification_add Send notification prompt function, notification
notification_add($touid, $type, $note, $notevars = array(), $system = 0)
$touid : Who to send to?
$type: method? Commonly used is post
$note: You can edit the content yourself
$notevars = some content parameters
$system = 0 by default
Add the following code to line 139 of the souse/class/module/module_forum_thread.php file
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.' published: '.$bt, array('from_id' => 0,
'from_idtype' => 'sendnotice'), 1);
}
}
Implementation effect: If any member of the group posts a message in the group, all members of the group will receive a system reminder and be prompted for a system reminder.
author:Beyond If you have any questions, please join the group
http://www.bkjia.com/PHPjc/935347.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/935347.htmlTechArticleDISCUZ Change the group posting system to remind members notification_add Send notification prompt function, notification notification_add($touid, $type, $ note, $notevars = array(), $system = 0)$touid...
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn