Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mrkdevelopment/4d190d6ef34cdc5083852d1b731052e8 to your computer and use it in GitHub Desktop.
Save mrkdevelopment/4d190d6ef34cdc5083852d1b731052e8 to your computer and use it in GitHub Desktop.
WordPress filter to change diviframework faq post type args
<?php
// Add this to your child theme's function.php file.
// Make sure you flush the rewrite rules.
// On wp cli you can 'wp rewrite flush'
// Or goto WordPress Admin > Settings > Permalink and save the settings which will flush the rules.
add_filter(
'df_faq_post_type_args',
function ($args) {
$args['public'] = true;
$args['exclude_from_search'] = false;
return $args;
},
100
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment