afish

最近收到一些通过Contact Us进行垃圾外链群发的邮件,虽然可以通过在Contact Us增加验证码来解决,但不利于客户体验。
所以我们可以通过简单的关键词过滤来实现,一般垃圾外链都含有“[url=”形式的代码

查找includes\modules\pages\contact_us\header_php.php

// Send message
zen_mail($send_to_name, $send_to_email, EMAIL_SUBJECT, $text_message, $name, $email_address, $html_msg,\'contact_us\');

修改为

// Send message
if(!strstr(strtolower($_POST[\'enquiry\']), \'[url=\')){
  zen_mail($send_to_name, $send_to_email, EMAIL_SUBJECT, $text_message, $name, $email_address, $html_msg,\'contact_us\');
}

 

分类:

技术点:

相关文章:

  • 2021-11-21
  • 2021-11-30
  • 2022-12-23
  • 2022-12-23
  • 2021-11-21
  • 2021-05-31
  • 2021-04-19
猜你喜欢
  • 2021-06-19
  • 2021-11-21
  • 2021-11-21
  • 2021-12-21
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案