Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

contact form extension database on a required field WordPress

  • REFUNDED

Hello, I need help in connecting a database to a required field on my contact form that i am using with Themeforest (Mestro Animated theme)b that downloaded into WordPress. I am using the contact7 form I uploaded in wordpress or I can use the form that comes with the theme. In either case, one of my required fields need to query a database in order to pass validation on that field.

The database will consist of building names. The list will be modified from time to time, therefore, it needs to be accessible for wordpress admin users to add, delete or edit a building name as they please. We would also like for the fields to auto populate when editing the database (adding, modifying). For example, if I add this building address to the database 11478 Grant Street today. Then tomorrow if I add 11478.....Hope street. It should cache 111478 or auto populate those numbers as I type; i guess kind of like what your typical browser would do when you typing in a URL and it remembers your browsing history, so therefore it auto populates what it thinks you are trying to type or search for.

The enduser must provide their building name in that field. If their building name does not match one of the building names in the database, then the valdiation should fail. Otherwise, it should pass and allow the user to enter another page listing the coupons and deals for those particular clients.

So, I need to know how to setup the database first...like where do i go to set that up and how to set it up with the building names, how do i link it somehow to the contact form and setup the pass/fail validation on one of the fields on that form.

How do I do that on this form? Or is there a plugin that does all of this for me( the database, the required field, the database extension), etc.

Thanks!

Answers (2)

2014-04-08

Arnav Joy answers:

So you need two things
1. In admin where you can add edit delete entries.
2. In front a validation check as per admin entry

I sent you pm please check.


mariechild comments:

I need a contact form that will have one required field. The required field needs to query the database before allowing the user to open up the next page. The database will consist of buiding names . The user must enter one of the building names in the database in the required field in order to proceed to the next page. In other words, that required field needs to query the database. Once it queries the database and the validation passes, then the page should automatically open up a new page so the user can view deals and orders that our company may have.

2014-04-10

Jason Bruno answers:

there is an extension called CFDB for contact form 7 which can capture, save, and export your contact form 7 submissions
you can start there if you want other database functions to edit some entries.
here's a link to the wordpress repository http://wordpress.org/plugins/contact-form-7-to-database-extension/

* I am not related to the plugin but you can contact me if you want custom work based on this