1

I'm building my site with a Laravel frontend. The idea is that I can build the website in Laravel and simply use WordPress as a CMS for the content.

I'm using Corcel to achieve this and so far it is working very well.

One thing I need to do is implement a contact form. Ideally I'd like to use Laravel functionality, such as validation and saving. However I need the form submissions to appear in the WordPress admin.

What is the best way to do this? Do I need to create a custom post type? The admin won't need to edit any of the submissions, just merely view them and delete them.

Do I need to create the fields in WordPress first and then reference those fields in my Laravel view?

I also have use of Advanced Custom Fields if this helps.

1 Answer 1

0

There is a plugin by the creators of ContactForm7, called Flamingo, intended to saving the comments people does in pages, etc. Actually it uses custom post-types to capture the comments people send. To take advantage of it you should store the submissions of your form as comments, if you are hesitant of importing the comments api (via require it), you could use the REST API to make submissions to the WP backend.

https://contactform7.com/save-submitted-messages-with-flamingo/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.