热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

电子邮件管道到PHP脚本有时只工作-Emailpipetophpscriptworkingonlysometimes

Ihaveaphppipescriptthatreceivesanemail,takesanattached*.csvfromitandparsesit.我有一

I have a php pipe script that receives an email, takes an attached *.csv from it and parses it.

我有一个php管道脚本,它接收一封电子邮件,从中获取附加的* .csv并解析它。

However, when the email is sent from where it is supposed to be coming from, it silently errors. But when I take that same email and resend it from my address it goes through just fine. is there any simple reason it could be doing this?

但是,当电子邮件从它应该来自的地方发送时,它会默默地发生错误。但是,当我接收同一封电子邮件并从我的地址重新发送时,它就会很好。有什么简单的理由可以做到这一点吗?

2 个解决方案

#1


0  

try and save some information about the email in a logfile before anything else, then some more info as you parse it. This way you get a more better understanding of what is happening

尝试在日志文件中先保存一些有关电子邮件的信息,然后再解析一些其他信息。通过这种方式,您可以更好地了解正在发生的事情

#2


0  

Is the email youa re sending from a real email? There may be a setting that allows emails to be sent from a valid user.

您是通过真实电子邮件发送的电子邮件吗?可能存在允许从有效用户发送电子邮件的设置。

What happens if you chown the script to be the user you want to send the email from. Does it work then?

如果您将脚本称为要从中发送电子邮件的用户,会发生什么情况。它有用吗?


推荐阅读
author-avatar
Cindy_J_Lee
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有