wordpress数据表_如何在WordPress数据库中保存联系表数据

wordpress数据表

Recently one of our readers asked if it’s possible to save WordPress contact form data in the database?

最近,我们的一位读者问是否可以在数据库中保存WordPress联系人表单数据?

Typically most popular WordPress form plugins will send a notification email to administrators after a form entry is submitted on the website.

通常, 大多数流行的WordPress表单插件都会在网站上提交表单条目后向管理员发送通知电子邮件。

But what happens to this data after it’s sent? In this article, we will share how to save contact form data in the WordPress database, and what does it actually mean.

但是,这些数据发送后会怎样? 在本文中,我们将分享如何在WordPress数据库中保存联系表单数据,以及它的实际含义。

Saving your contact form data in your WordPress database
联系表格和WordPress数据库(幕后) (Contact Form and the WordPress Database (Behind the Scenes))

When a visitor submits a contact form on your WordPress site, the most prominent visible action that you as a website owner will see is an email notification in your inbox that contains all the details that specific visitor submitted.

当访问者在您的WordPress网站上提交联系表单时,作为网站所有者,您最明显的可见操作是收件箱中的电子邮件通知,其中包含特定访问者提交的所有详细信息。

However behind the scenes, most WordPress form plugins will also store this data in your WordPress database.

但是,在幕后,大多数WordPress表单插件也将这些数据存储在WordPress数据库中。

A WordPress database is a system of storing and fetching data in an organized way. This allows plugin developers to manage data in a programmable way.

WordPress数据库是一种以组织方式存储和获取数据的系统。 这允许插件开发人员以可编程方式管理数据。

As a user, if you wanted to display the data in your WordPress database, then you would need to login to your WordPress hosting account and go to the phpMyAdmin tool.

作为用户,如果要在WordPress数据库中显示数据,则需要登录到WordPress托管帐户并转到phpMyAdmin工具。

For example, if you’re using Bluehost, then the link to phpMyAdmin is at the bottom of the control panel under Helpful Links » Advanced » phpMyAdmin.

例如,如果您使用的是Bluehost ,则phpMyAdmin的链接位于控制面板底部的“有用的链接”»“高级”»phpMyAdmin下。

Once you’re in phpMyAdmin, you’d need to select your WordPress database, then click on the database table of your respective WordPress form plugin. Since we use WPForms, this is our form table: wp_wpforms_entries.

进入phpMyAdmin后,您需要选择WordPress数据库,然后单击相应WordPress表单插件的数据库表。 由于我们使用WPForms ,因此这是我们的表单表: wp_wpforms_entries

The wp_wpforms_entries and wp_wpforms_entry_meta tables shown in the phpMyAdmin list

Once you’ve clicked on the table, you’ll find all your form entries in the fields column.

单击表格后,您将在字段列中找到所有表单条目。

Contact Form Data Fields in WordPress Database phpMyAdmin View

Giving the looks of it, you will agree with us when we say that this is not the most user-friendly way to see data.

给出它的外观,当我们说这不是查看数据的最人性化的方式时,您将同意我们的观点。

This is why most premium WordPress form plugins come with a user-friendly entry management solution that allows you to access form entries inside your WordPress dashboard.

这就是为什么大多数高级WordPress表单插件都附带了一个用户友好的条目管理解决方案,允许您访问WordPress仪表板中的表单条目。

Yes, all contact form data is still stored in your WordPress database, but you can view it in a user-friendly interface like your WordPress admin instead of the screenshot above.

是的,所有联系表单数据仍存储在WordPress数据库中,但是您可以在用户友好的界面(如WordPress管理员)中查看它,而不是上面的屏幕截图。

Let’s take a look at an example of what it looks like when using WPForms, which is the fastest growing premium WordPress form plugin, and it’s currently being used by over 3 million websites.

让我们看一个使用WPForms时的外观示例, WPForms是增长最快的高级WordPress表单插件,目前有300万个网站在使用它。

如何在WordPress中管理联系表单条目 (How to Manage Contact Form Entries in WordPress)

For the sake of this example, we will be using WPForms because that’s the plugin built by our team, and it is what we use on WPBeginner. However similar process exists in other popular WordPress form plugins like Formidable Forms, and others.

在本示例中,我们将使用WPForms,因为这是我们团队构建的插件,也是我们在WPBeginner上使用的插件。 但是,其他流行的WordPress表单插件(例如Formidable Forms)等也存在类似的过程。

First, you will of course need to create a contact form with WPForms. If you need instructions for this, then you can follow our step by step guide on how to create a contact form in WordPress.

首先,您当然需要使用WPForms创建联系表。 如果您需要相关说明,则可以按照我们的逐步指南进行操作,以了解如何在WordPress中创建联系表单

After you have added the contact form on your website, you need to go ahead and make a test entry submission. Here’s an example of our simple contact form:

在网站上添加联系表之后,您需要继续进行测试条目提交。 这是我们的简单联系表的示例:

A simple contact form, showing fields for Name, Email, and Comment or Message

Once you have filled it out with sample information, click on Submit.

用示例信息填写完后,单击“提交”。

This will cause two things to happen. First, it will send you, the site admin, an email with all the information from the form. Second, it will store the contact form data in your WordPress database which you can view on the WPForms » Entries section in the WordPress dashboard.

这将导致两件事发生。 首先,它将向您(网站管理员)发送一封电子邮件,其中包含表单中的所有信息。 其次,它将联系表单数据存储在您的WordPress数据库中,您可以在WordPress仪表板的WPForms»Entries部分中查看。

The WPForms Entries Overview page, showing a graph and a table with the form name and number of entries

From this screen, you can click on your form’s name, or the count under the All Time to see your entry.

在此屏幕上,您可以单击表单名称或“所有时间”下的计数以查看您的输入。

Table showing entered form data for name, email, and comment or message

The field labels (in this case, Name, Email, and Comment or Message) are listed at both the top and the bottom of the table.

字段标签(在这种情况下,名称,电子邮件以及评论或消息)在表格的顶部和底部均列出。

The entry management screen also gives you an ability to star (favorite) entries in the table, mark them as read, or even delete them.

条目管理屏幕还使您能够对表中的条目加注星标(收藏),将其标记为已读,甚至删除它们。

You can click on the View link next to the entry item to see more details such as date of submission, other contact form fields, etc.

您可以单击条目旁边的“查看”链接以查看更多详细信息,例如提交日期,其他联系表单字段等。

The View link, indicated by a red arrow, that you click to view the contact form entry details

On the WPForms entry details page, you can add notes about the contact form entry, print or export it, star it, and more.

在WPForms条目详细信息页面上,您可以添加有关联系表单条目的注释,打印或导出,加注星标等等。

The page showing all the details about the contact form entry

As a user, this interface is much more user friendly way to view the contact form data stored in a WordPress database.

作为用户,此界面是一种更加用户友好的方式,用于查看存储在WordPress数据库中的联系表单数据。

温馨提示:如何禁止将表单数据存储在WordPress数据库中 (Bonus Tip: How to Disable Form Data from being Stored in WordPress Database)

In some cases, you may not want to store your contact form data in a WordPress database. WPForms also allows you to do that. All you need to do is edit the respective WordPress form, and it will open the WPForms form builder.

在某些情况下,您可能不想将联系表单数据存储在WordPress数据库中。 WPForms还允许您执行此操作。 您需要做的就是编辑相应的WordPress表单,这将打开WPForms表单构建器。

You need to go to the Settings » General tab inside the builder and scroll to the bottom. You need to make sure to check the option that says: Disable storing entry information in WordPress.

您需要转到构建器内的“设置”»“常规”选项卡,然后滚动到底部。 您需要确保选中以下选项:禁用在WordPress中存储条目信息。

Disable Entry Storing on WPForms

After that, simply click on the Save Button and you’re done.

之后,只需单击“保存”按钮即可。

Now you need to go back to this form and submit a test entry to make sure that you’re receiving email notifications. This is very important because the contact form entry will NOT be stored in the database when you have the above setting checked.

现在,您需要返回到此表单并提交测试条目,以确保您正在接收电子邮件通知。 这非常重要,因为当您检查了以上设置后,联系表条目将不会存储在数据库中。

If you’re running into the WordPress not sending email issue, then you need to install and activate WP Mail SMTP plugin. It helps you improve WordPress email deliverability by letting you connect with top SMTP providers like Amazon SES, SendGrid, etc.

如果您遇到WordPress无法发送电子邮件的问题 ,则需要安装并激活WP Mail SMTP插件 。 通过与顶级SMTP提供商(例如Amazon SES,SendGrid等)建立连接,它可以帮助您提高WordPress电子邮件的可传递性。

That’s all. We hope this article helped you learn how to save contact form data in the WordPress database. You may also want to see our guide on the best email marketing services to help increase your website traffic and sales.

就这样。 我们希望本文能帮助您学习如何将联系表单数据保存在WordPress数据库中。 您可能还希望查看有关最佳电子邮件营销服务的指南,以帮助增加您的网站流量和销售量。

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

如果您喜欢这篇文章,请订阅我们的YouTube频道 WordPress视频教程。 您也可以在TwitterFacebook上找到我们。

翻译自: https://www.wpbeginner.com/wp-tutorials/how-to-save-contact-form-data-in-the-wordpress-database/

wordpress数据表

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值