如何从我的网站发送电子邮件? [英] How do I send email from my website?
问题描述
在这种形式中,我创建了四个文本框,一个重置按钮和一个发送按钮。问题是当我点击该按钮时,不会发送邮件。我要用什么代码发送电子邮件?
如果你想从一个表单发送电子邮件这将是一个很好的了解服务器端脚本的想法。
我将从找到您当前服务器上安装的软件开始。例如:它是一个具有Apache,MySQL,PHP,Perl等的Linux服务器,还是ASP.NET等的Windows服务器?您可以从主机提供商那里找到这一点。
出于安全考虑,我不建议你自己写脚本来发送电子邮件,直到你知道你在做什么。有免费的脚本可以正常工作。
Tectite FormMail 是一个例子,如果你有PHP
然后你需要能够将所需的脚本上传到Web服务器。通常FTP服务器的访问权限用于此任务。并使用适当的HTML与脚本进行通信。
或者:
有托管表单选项可能值得检查,所以您不必一样了解服务器脚本。 (这意味着一些其他的网络服务器,您所管理的电子邮件部分是HTML)
I am working on a website. I am new to this field. I've made one website, but I have a problem in the "Contact Us" form.
In this form I made four textboxes, one "reset" button, and one "send" button. The problem is that when I click on that button, mail is not sent. What code do I have to use to send email?
If you want to send emails from a form it would be a good idea to learn about server-side scripts.
I would start by finding out what software you have installed on your current server. Eg: is it a Linux server with Apache, MySQL, PHP, Perl etc... or is it a Windows server with ASP.Net etc... You can find this out from your host provider.
For security reasons I would not recommend writing your own script for sending emails until you know what you are doing. There are freely available scripts that do this fine.
Tectite FormMail is one example if you have PHP
Then you need to be able to upload your required scripts to the web server. Usually FTP access to the server is given for this task. And use the appropriate HTML to communicate with the script.
Alternatively:
There are hosted form options that may be worth checking out so you don't have to learn as much about server scripts. (this means some other web server does the email part all you manage is the HTML)
Here is a list of a few hosted options
Edit: Here is a better list of hosted options
这篇关于如何从我的网站发送电子邮件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!