Discuz sendmail函数实现 发表回帖邮件通知楼主方法
打开目录:source\include\post
找到文件:post_newreply.php
找到下面代码:
在这段代码之前添加如下代码:
即可实现回帖邮件通知楼主!
找到文件:post_newreply.php
找到下面代码:
if(!isset($inspacecpshare)) { showmessage($return , $url, $modpost->param('showmsgparam')); } |
if($firstpost['author'] != $_G['uid']){ $tomail = reset(C::t('common_member')->fetch_all_by_username($firstpost['author'])); $mail_subject = '您的帖子有新回复!'; $mail_message = <<<EOT <table cellpadding="6" cellspacing="0" width="100%" style="width:650px;margin:0 auto;font-size:12px;"> <tbody><tr> <td width="640" style="border-bottom:1px solid #e0e0e0;text-align:right;" colspan="2"> <table cellpadding="0" cellspacing="0"> <tbody><tr> <td valign="bottom"><img src="http://www.dz7.com.cn/template/dz7_tuhao1/images/logo.png" style="vertical-align: bottom"></td> <td width="600" style="text-align:right" valign="bottom"><a href="http://www.dz7.com.cn/member.php?mod=logging&action=login" style="font-size:14px;color:#0082d5;text-decoration:none;" target="_blank">登录</a> | <a href="http://www.dz7.com.cn/member.php?mod=register" style="font-size:14px;color:#0082d5;text-decoration:none" target="_blank">注册</a></td> </tr> </tbody></table> </td> </tr> <tr> <td style="font-size:14px;line-height:25px;">尊敬的DZ起点网会员:<span style="border-bottom: 1px dashed rgb(204, 204, 204); z-index: 1; position: static;" t="7" data="{$firstpost['author']}" isout="1">{$firstpost['author']}</span><br><br>有新网友回复了您在起点网发布的帖子《<a href="http://www.dz7.com.cn/discuz-{$firstpost['tid']}-1-1.html" target="_blank">{$firstpost['subject']}</a>》<br><br>详情请点击这里打开查看:<a href="http://www.dz7.com.cn/discuz-{$firstpost['tid']}-1-1.html">http://www.dz7.com.cn/discuz-{$firstpost['tid']}-1-1.html</a>。<br><br>DZ起点网,您的坚强后盾!</td> </tr> <tr> <td style="text-indent:1.3em;font-size:14px;line-height:25px;border-bottom:1px solid #e0e0e0"><br></td> </tr> <tr> <td style="color:#8a8a8a;font-size:12px;padding-left:24px;line-height:20px;"><br><div style="text-align: center;"><img src="https://set3.mail.qq.com/cgi-bin/download?sid=o98wstGkas_ITGI6&upfile=nnTDFYo6EOWktJwwFfeKsGThsfTBA4MSoChZT6Ln501bLjpernjAItEu3H8eNv0v4MVo7imxxO%2F9K7OhWM3L5EbZqCtNtEA4PiDgltAlJP7b6cJiwrTeNsbLmCITuQMI" modifysize="25%" diffpixels="-1px" style="width: 124px; height: 125px;"> </div><div style="text-align: center;"><span style="text-align: start;">如有任何疑问,可以添加DZ起点网站长QQ、微信进行咨询!</span></div></td> </tr> <tr> <td style="color:#8a8a8a;font-size:12px;padding-left:24px;line-height:20px;">每一位DZ起点网的会员人,都在默默无闻的,帮助着新手站长朋友快速成长,解决站长朋友们在建站过程中的疑问!<br><div style="text-align: right;">-- DZ起点网</div></td></tr> </tbody></table> EOT; if(!function_exists('sendmail')) { include libfile('function/mail'); } sendmail($tomail['email'], $mail_subject, $mail_message); } 复制代码 |
即可实现回帖邮件通知楼主!
免责声明:本站所有文章和图片均来自用户分享和网络收集,文章和图片版权归原作者及原出处所有,仅供学习与参考,请勿用于商业用途,如果损害了您的权利,请联系网站客服处理。
热门教程
discuz电脑版、手机版去除标题title中的PoweredbyDisc2018-12-27
Discuz 触屏手机版支持视频播放的方法2018-12-27
discuz手机版支持视频播放的修改方法2018-12-27
Discuz! 程序 X3.2、X3.3升级3.4教程2018-12-27
discuz X3以及X3.4论坛搬家完美详细教程2019-01-02
怎么开启手机版2018-12-25
去掉Discuz论坛底部的Powered 等版权信息2018-12-27
discuz! x3.4插件位置DZ论坛X3版本插件在哪个文件夹?2018-12-26
Mysql修改端口号后织梦dedecms的修改方法2018-12-27
Discuz!X3.2论坛实现全站HTTPS终极方法教程2018-12-28