caldera_forms_autopopulate_post_type_args

An Image of a Kitten Sitting on Grass

This filter allows you to change the WP_Query arguments used to auto-populate a field with posts or custom post type items.

Populate Caldera Forms Select Field With Posts From A Specific Category

See Codex for information on category arguments.

Populate Caldera Forms Select Field With Posts Excluding A Specific Category

 

 

Where Does This Code Go?

When using WordPress hooks to customize Caldera Forms or other plugins you should not modify the plugin files, or you will lose your changes when you update the plugin. Instead you should create a small plugin to hold the custom code. It's easy, learn how here.

Technically you can add the custom code to your theme's functions.php, but then you will not be able to change your theme and keep these customizations.

Learn More