在 SWFUpload 上发送电子邮件确认
不确定你们中是否有太多人熟悉 SWFUpload。这是一个基于 flash/js/php 的上传脚本。我的主要问题是我对 php 非常熟悉,我可以在其中创建一个简单的 mail() 脚本,但是,对于各种 JS 文件,我不确定在 JS 中创建邮件函数是否会更好。
如果有人有使用 SWFUpload 的经验,请告诉我上传完成后可以在哪里创建脚本。
提前致谢。
Not sure if too many of you are familiar with SWFUpload. It's a flash/js/php based uploading script. My main issue is that I'm decently fluent in php where I can create a simple mail() script, however, with the various JS files I'm not sure if it'd be better to create the mail function in JS.
If anyone has had experience with SWFUpload please advise me as to where I can create a script after the upload has completed.
Thanks in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我百分百确定几周前有人问过同样的问题,但我找不到重复的内容。无论如何,结论是:
您不能将电子邮件的发送放入接收文件的 PHP 或 ASP 脚本中,因为这不适用于多次上传(每个都有自己的脚本实例)< /p>
您需要对发送电子邮件的 PHP 文件的 Ajax 调用,并将该调用放入 SWFUpload 的
complete
(或success
)回调中。I'm 100% sure somebody asked the same thing a few weeks ago, but I can't find the duplicate. Anyway, the conclusion was:
You can't put the sending of the E-Mail into the PHP or ASP script that receives the file, as that won't work for multiple uploads (each gets its own script instance)
You need to make an Ajax call to a PHP file that sends the E-Mail and place that call into the
complete
(orsuccess
) callback of SWFUpload.