How to Exclude on certain pages
-
HI Danny,
Thanks for another really useful and well-coded plugin solution. I wanted this to only appear on pages which your settings handle perfectly. But of course there were a few pages I wanted it excluded from as well. So based on your FAQ code examples I threw together this function to exclude. Maybe not the most efficient function ever but it does the job:
function my_display_condition() { global $post; $excludeids = array(2,12, 14, 140); if (in_array($post->ID, $excludeids)) { } else { return is_singular('page'); } } add_filter('dvkss_display', 'my_display_condition');
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘How to Exclude on certain pages’ is closed to new replies.