donglu5612 2010-04-28 07:57
浏览 36
已采纳

帮助内联图像/电子邮件与cron - php?

I've got mailings that need to be sended using cron. When I load the script manualy all works fine. With cron i get broken images.

to change the src of my img i used:

$body    = eregi_replace("managersrc_logo","images/managers/acertainlogo.jpg",$body);

Because i thaught that it is importent to use absolute paths i also tried:

$body    = eregi_replace("managersrc_logo","http://www.site.com/images/managers/acertainlogo.jpg",$body);

In that case i even do not see the images when i run the cronscript manualy. Nor the automated cron will display me the images.

When i check the source of the mail that is received i always see "cid:encryptedstuff" even if i use absolute paths? Why is that? I just want my absolute paths being printed in the src attribute of the img tag. Who changes my absolute path to cid: ? is it php, phpmailer or outlook itself?

Any help someone?

  • 写回答

2条回答 默认 最新

  • dreamfly0514 2010-04-28 14:56
    关注

    The problem was an older version of phpmailer. I updated to the new version and the images are displayed perfectly now!!

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥20 给自己本科IT专业毕业的妹m找个实习工作
  • ¥15 用友U8:向一个无法连接的网络尝试了一个套接字操作,如何解决?
  • ¥30 我的代码按理说完成了模型的搭建、训练、验证测试等工作(标签-网络|关键词-变化检测)
  • ¥50 mac mini外接显示器 画质字体模糊
  • ¥15 TLS1.2协议通信解密
  • ¥40 图书信息管理系统程序编写
  • ¥20 Qcustomplot缩小曲线形状问题
  • ¥15 企业资源规划ERP沙盘模拟
  • ¥15 树莓派控制机械臂传输命令报错,显示摄像头不存在
  • ¥15 前端echarts坐标轴问题