How to display custom post type as a drop-down field in Contact Form 7

Hello, my first post here. Recently I had a client who wanted to show custom post type items as a choice in a Contact Form 7 form. If you think about it it makes a perfect sense.

An example: you have a custom post type Services and on the Contact page visitor can select service from a dropdown field. We will solve this with a custom form tag, functionality built into Contact Form 7. Here is the complete code:



Leave a Reply

Your email address will not be published. Required fields are marked *