本文实现PHP发送带excel的邮件大致思路如下:首先生成二维数组,并导入到excel文件当中。然后用phpmailer把生成的文件发送到邮件当中。include_once 'function.php'; <br>
$email = $_POST['email']; <br>
$titles = array("id", "时间", "名称"); //excel 列 <br>
$datas = array( <br>
0 => array( <br>
"id" => "1", <br>
"date" => date("Y-m-d", strtotime("-1 day")), <br>
"name" => "素材火" <br>
), <br>
1 => array( <br>
"id" => "2", <br>
"date" => date("Y-m-d"), <br>
"name" => "分享微博送30积分" <br>
), <br>
); <br>
$file_name = date("Y-m-d") . "素材火excel发送"; <br>
$attachments = sendExcel($file_name, $titles, $datas);
PHP在线生成excel并发送邮件DEMO演示:http://www.sucaihuo.com/js/871.html
AD:真正免费,域名+虚机+企业邮箱=0元

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 English version
Recommended: Win version, supports code prompts!

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

ZendStudio 13.5.1 Mac
Powerful PHP integrated development environment

Safe Exam Browser
Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft
