Consider adding an option to disable archive display in the front end
-
Frank, have you considered exposing an option to disable front-end display? The use case is for using the plugin to shelve old content without deleting it, so that it can be restored if necessary, but definitely hiding it from public view. We’re currently accomplishing this via the function below in a custom site plugin, which feels a bit hacky.
/* Disable Archived posts from being visible in the front end */ function rli_hide_archiv_posts() { global $wp_post_types; $archiv = &$wp_post_types['archiv']; $archiv->publicly_queryable = 0; $archiv->has_archive = 0; } add_action( 'init', 'rli_hide_archiv_posts', 100 );
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Consider adding an option to disable archive display in the front end’ is closed to new replies.