创建一个将指定的信息发送到特定邮件地址的表单 [英] creating a form that will send the information specified to a specific mail adress

查看:172
本文介绍了创建一个将指定的信息发送到特定邮件地址的表单的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在网站上创建一个非常简单的表单。

I want to create a very simple form on a website.

表单应包含各种信息,如日期,时间,XX地址XX等。 b $ b当您单击提交时,应将数据发送到处理这些请求的特定邮件。

The form should contain various information such as date, time, how many XX address XX etc. When you click "submit" the data should be send to a specific mail handling these requests.

我知道应该相当简单, ve以前从未使用过数据库。

I know it should be fairly simple to make, but I've never used databases before.

我非常希望以selfhelp的形式提供帮助。 :)

I would very much prefer help in the form of selfhelp. :)

谢谢!

推荐答案

只是将数据从表单发送到电子邮件,数据库不必涉及。数据库用于存储和查询数据,您不需要这样做。

If you want to just send data from a form to email, a database doesn't have to be involved. A database is for storing and querying data, which you don't need to do.

您需要一个软件(而不是存储在静态文件),它将读取提交的表单数据,构造并发送电子邮件,并通过服务器的邮件服务器发送。

You need a piece of software (instead of a plain HTML document stored in a static file) that will read the submitted form data, construct and email, and send it via your server's mail server.

服务器可以使用多个接口运行程序包括通用方法(如FastCGI或CGI)到语言/服务器特定的方法(如mod_perl或mod_php)。您使用的语言将取决于您选择的编程语言和您的服务器支持。

There are a number of interfaces that a server can use to run the program including generic methods (such as FastCGI or CGI) to language/server specific methods (such as mod_perl or mod_php). Which you use will depend on your choice of programming language and what your server supports.

然后您只需要根据您选择的界面编写程序对于任何标准语言你可以命名的任何语言的图书馆)读取表单数据(将以特定于界面的格式,该库将处理)和发送电子邮件(再次,有电子邮件发送

Then you just need to write the program against the interface you picked (there are no shortage of libraries for just about any language you could name for any of the standard ones) to read the form data (which will be presented in an interface-specific format that said library will deal with) and send email (again, there are email sending libraries for just about everything).

如果你只想要一个通用的表单到电子邮件处理程序,你可能会找到一个预写的脚本。

You can probably find a prewritten script if you just want a generic form-to-email handler.

这篇关于创建一个将指定的信息发送到特定邮件地址的表单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆