本文主要讲解《织梦dedecms系统自定义表单提交之后如何发送到邮箱》的详细内容
$mailtitle = $name."提交表单通知"; $mailbody = "称呼:{$name}\r\n邮箱:{$email}\r\n内容:{$message}"; $headers = $cfg_adminemail; $mailtype = 'TXT'; require_once(DEDEINC.'/mail.class.php'); $smtp = new smtp($cfg_smtp_server,$cfg_smtp_port,true,$cfg_smtp_usermail,$cfg_smtp_password); $smtp->debug = false; $smtp->sendmail($cfg_smtp_usermail,$cfg_webname ,$cfg_smtp_usermail, $mailtitle, $mailbody, $mailtype);注:$name $email $message 三个变量都是提交的字段,你提交的字段名称前面加$符号就行,这个根据你的需要来改。然后保存。
本网刊登的文章均仅代表作者个人观点,并不代表本网立场。文中的论述和观点,敬请读者注意判断。
2021-02-08
2021-02-08
2021-02-08
2021-02-08
2021-02-24
2021-02-08
2021-02-24
2021-02-08