织梦DEDECMS文章被评论后发短消息给作者的方法


DEDECMS文章被别人评论后系统短消息通知作者的代码成功,现在特别将方法分享给大家,需要修改的文件是:feedback.php。找到:

$inquery = "INSERT INTO `dede_feedback`
(`aid`,`typeid`,`username`,`arctitle`,`ip`,`ischeck`,`dtime`, `mid`,`bad`,`good`,`ftype`,`face`,`msg`)
         VALUES ('$aid','$typeid','$username','$arctitle','$ip',
'$ischeck','$dtime', '{$cfg_ml->M_ID}','0','0','$feedbacktype','$face','$msg'); ";
$rs = $dsql->ExecuteNoneQuery($inquery);

修改为:
$inquery = "INSERT INTO `dede_feedback`(`aid`,`typeid`,`username`,

`arctitle`,`ip`,`ischeck`,`dtime`, `mid`,`bad`,`good`,`ftype`,`face`,`msg`)
                  VALUES ('$aid','$typeid','$username','$arctitle','$ip','$ischeck',

'$dtime', '{$cfg_ml->M_ID}','0','0','$feedbacktype','$face','$msg'); ";
$inquery1 = "INSERT INTO `dede_member_pms` (`floginid`,`fromid`,`toid`,

`tologinid`,`folder`,`subject`,`sendtime`,`writetime`,`hasview`,`isadmin`,`message`)
                   VALUES ('admin','1','$mid','$writer','inbox','你的《{$arctitle}》有新的评论',

'$dtime','$dtime','0','0','{$cfg_ml->M_LoginID}说:{$msg}'); ";
$rs = $dsql->ExecuteNoneQuery($inquery);
$rs = $dsql->ExecuteNoneQuery($inquery1);

评论

大侠名号:   验证码: 点击我更换图片  

修远兮

在这里记录每一点自己需要的知识

添加创始人微信,一起交流心得

推荐文章RECOMMEND