简体   繁体   English

SMTP、PHP.ini 设置,用于简单的外发邮件演练

[英]SMTP, PHP.ini setup for simple outgoing mail walkthrough

i have been having this problem for weeks now, i cant seem to understand and do correctly configuring of my php.ini and an smtp server to send email from the website i am developing.我已经有这个问题好几个星期了,我似乎无法理解并正确配置我的 php.ini 和 smtp 服务器以从我正在开发的网站发送 email。

I really need a walkthrough that also includes suggestions on what smtp server software to download so that it includes examples on how to integrate it into php.我真的需要一个演练,其中还包括有关下载什么 smtp 服务器软件的建议,以便它包含有关如何将其集成到 php 的示例。

I really hope someone can help me with this.我真的希望有人可以帮助我。 I need to finish this website for my college dissertation and i have no idea on how to use smtp我需要为我的大学论文完成这个网站,但我不知道如何使用 smtp

this is the first time i am using this feature so i am very new to this stuff这是我第一次使用这个功能,所以我对这个东西很陌生

Have you tried ini_set() ?你试过ini_set()吗? You don't need to install any server software for this, most of the web server supports SMTP, just need to enable it.不需要为此安装任何服务器软件,web服务器大部分都支持SMTP,只需要启用即可。

<?php
// Using the ini_set() 
ini_set("SMTP", "smtp_server");
ini_set("sendmail_from", "email@example.com");
//ini_set("smtp_port", "20"); // for example

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM