Title: Exclude Pages
Author: Simon Wheatley
Published: <strong>Gwengolo 22, 2007</strong>
Last modified: Mezheven 13, 2012

---

Search plugins

This plugin **hasn’t been tested with the latest 3 major releases of WordPress**.
It may no longer be maintained or supported and may have compatibility issues when
used with more recent versions of WordPress.

![](https://s.w.org/plugins/geopattern-icon/exclude-pages.svg)

# Exclude Pages

 By [Simon Wheatley](https://profiles.wordpress.org/simonwheatley/)

[Download](https://downloads.wordpress.org/plugin/exclude-pages.1.92.zip)

 * [Details](https://bre.wordpress.org/plugins/exclude-pages/#description)
 * [Reviews](https://bre.wordpress.org/plugins/exclude-pages/#reviews)
 *  [Installation](https://bre.wordpress.org/plugins/exclude-pages/#installation)
 * [Development](https://bre.wordpress.org/plugins/exclude-pages/#developers)

 [Support](https://wordpress.org/support/plugin/exclude-pages/)

## Description

This plugin adds a checkbox, “include this page in menus”, uncheck this to exclude
pages from the page navigation that users see on your site.

Any issues: [contact me](http://www.simonwheatley.co.uk/contact-me/).This plugin
adds a checkbox, “include this page in menus”, which is checked by default. If you
uncheck
 it, the page will not appear in any listings of pages (which includes, 
and is _usually_ limited to, your page navigation menus).

Pages which are children of excluded pages also do not show up in menu listings.(
An alert in the editing screen,
 underneath the “include” checkbox allows you to
track down which ancestor page is affecting child pages in this way.)

### Advanced Usage

It is possible to temporarily pause and resume the effect of Exclude Pages by using
the new `<?php pause_exclude_pages(); ?>` and `<?php resume_exclude_pages(); ?>`
templates tags. The following code will show a list of all pages in your site, even
those normally hidden:

    ```
    <?php pause_exclude_pages(); ?>
    <?php wp_list_pages('title_li=<h2>Pages</h2>' ); ?>
    <?php resume_exclude_pages(); ?>
    ```

You can also get an array the IDs of the pages which are excluded by calling the
function `ep_get_excluded_ids();`, you can then use these IDs as you wish (e.g. 
feed them into raw MySQL queries).

Note to other plugin authors:

The plugin does not operate on wp_list_pages while the user is on an admin page,
if this is an issue you can take advantage of the `ep_admin_bail_out` filter and
create a filter function which returns false to allow Exclude Pages to operate in
the admin area.

Another note:

If your plugins or themes don’t use the standard WordPress functions to create their
menus then they won’t work. To get them to work you will need to track down the 
bit of code in the theme/plugin which gets the pages and change it to apply the 
filter “get_pages” (I cannot be responsible for any unforseen effects of the changes
you make, so please test thoroughly). The change to getting pages will probably 
look something like this:

    ```
    $pages = apply_filters( 'get_pages', $pages );
    ```

Please [contact me](http://www.simonwheatley.co.uk/contact-me/) if you’re completely
stuck and we can discuss possible solutions.

Exclude pages is incompatible with:

 * [WP CSS Dropdown Menus](https://wordpress.org/extend/plugins/wordpress-css-drop-down-menu/)
 * [Phantom theme](https://wordpress.org/extend/themes/phantom) – This theme

### Requests & Bug Reports

I’m simply noting requests & bug reports here, I’ve not necessarily looked into 
any of these.

_None!_

## Screenshots

 * [[
 * WP 2.5 – Showing the control on the editing screen to exclude a page from the
   navigation
 * [[
 * WP 2.5 – Showing the control and warning for a page which is the child of an 
   excluded page
 * [[
 * Pre WP 2.5 – Showing the control on the editing screen to exclude a page from
   the navigation
 * [[
 * Pre WP 2.5 – Showing the control and warning for a page which is the child of
   an excluded page

## Installation

 1. Upload `exclude_pages.php` to the `/wp-content/plugins/` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. Create or edit a page, and enjoy the frisson of excitement as you exclude it from
    the navigation

## FAQ

  Installation Instructions

 1. Upload `exclude_pages.php` to the `/wp-content/plugins/` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. Create or edit a page, and enjoy the frisson of excitement as you exclude it from
    the navigation

## Reviews

![](https://secure.gravatar.com/avatar/0dbe1bfd833918af8e9d8ae7388969e0b7c45c1b2631c4e1d1787bcf6e03c393?
s=60&d=retro&r=g)

### 󠀁[Still works with 6.6.1](https://wordpress.org/support/topic/still-works-with-6-6-1/)󠁿

 [jreynders](https://profiles.wordpress.org/jreynders/) Eost 6, 2024

Installed on wp6.6.1 php8.1. The plugin appears in prefect working condition in 
spite of is age.

![](https://secure.gravatar.com/avatar/80cb86a5a6844b71e69129aee232f66e1b521ae5cfe91713696e6dd46d36b84f?
s=60&d=retro&r=g)

### 󠀁[Still works with 5.3](https://wordpress.org/support/topic/still-works-with-5-3/)󠁿

 [jackreidy](https://profiles.wordpress.org/jackreidy/) miz Du 16, 2019

last update was years ago but it still works with WP 5.3

![](https://secure.gravatar.com/avatar/d97a0a63a9226b4ab4990e3726564e3e15dd6236ea0d660ed2c3c2f678dea9af?
s=60&d=retro&r=g)

### 󠀁[3 versions on and it still works!](https://wordpress.org/support/topic/3-versions-on-and-it-still-works/)󠁿

 [Gomisan](https://profiles.wordpress.org/gomisan/) Gwengolo 13, 2018

Unlike another plugin with a similar name, this plugin still works just fine with
my Wordpress sites and themes. A real shame that it has been abandoned, and I’d 
love to see an ‘updated’ version by someone.

![](https://secure.gravatar.com/avatar/e90b27522082813dd6e75923510121e6adac269a4b95101182e23d6dce477443?
s=60&d=retro&r=g)

### 󠀁[Works, although only with an edit](https://wordpress.org/support/topic/works-albeit-with-an-edit/)󠁿

 [mlipenk](https://profiles.wordpress.org/mlipenk/) Meurzh 23, 2018

This worked for me on WP 4.9.4 using PHP Version: 7.0.28, however only after editing
the plugin by changing: $parent = & ep_get_page( $page->post_parent, $pages ); to:
$parent = ep_get_page( $page->post_parent, $pages ); This also worked with side 
menus such as BE Subpages Widget, which uses wp_list_pages, not just navigation 
using standard functions wp_nav_menu or wp_page_menu. It is unfortunate the plugin
hasn’t been updated, because it is a good plugin that does exactly what I wanted…
allowing pages to be present in the site without automatically being listed in auto-
menus.

![](https://secure.gravatar.com/avatar/6955650dfc2336dd1f5601c9089ff5bc39b5d5c20f848724cce25ffdf64aee8b?
s=60&d=retro&r=g)

### 󠀁[Problem with PHP 5.6](https://wordpress.org/support/topic/problem-with-php-5-6/)󠁿

 [raygulick](https://profiles.wordpress.org/raygulick/) Ebrel 14, 2017 1 reply

This is an error encountered if your server is using PHP 5.6 or above, and if debugging
for your site is enabled. If you’re still using PHP 5.3, it works fine on WP 4.7.3.
It does not appear that the plugin author has any interest in updating this plugin,
or I would give it 5 stars. Any plugin developers who would like to fork and maintain
this plugin?

![](https://secure.gravatar.com/avatar/509df99036ac16a864779b192ae843ace823acfaa184bb25495771be8725eb64?
s=60&d=retro&r=g)

### 󠀁[Works perfect in 4.4](https://wordpress.org/support/topic/works-perfect-in-44/)󠁿

 [boris.klug](https://profiles.wordpress.org/borisklug/) Gwengolo 3, 2016

For me this plugin works perfect for hiding pages from the menus. I use the theme
Twenty Fourteen.

 [ Read all 47 reviews ](https://wordpress.org/support/plugin/exclude-pages/reviews/)

## Contributors & Developers

“Exclude Pages” is open source software. The following people have contributed to
this plugin.

Contributors

 *   [ Simon Wheatley ](https://profiles.wordpress.org/simonwheatley/)

[Translate “Exclude Pages” into your language.](https://translate.wordpress.org/projects/wp-plugins/exclude-pages)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/exclude-pages/), check
out the [SVN repository](https://plugins.svn.wordpress.org/exclude-pages/), or subscribe
to the [development log](https://plugins.trac.wordpress.org/log/exclude-pages/) 
by [RSS](https://plugins.trac.wordpress.org/log/exclude-pages/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### v1.92

 * BUGFIX: Fix deprecated notice when WP_DEBUG is true, thanks [hansfordmc](https://wordpress.org/support/topic/plugin-exclude-pages-cant-update-pages)
 * Tested up to WordPress v3.3

#### v1.91 2011/08/26

 * BUGFIX: Prevent notice from appearing, thanks [Ray](https://wordpress.org/support/topic/notice-undefined-index-1)

#### v1.9 2010/6/16

 * Tested with WP 3.2.1
 * ENHANCEMENT: Detects the use of WP menus and advises the user accordingly

#### v1.8.4 2010/5/21

 * LOCALISATION: Italian translation courtesy of [Gianni Diurno](http://gidibao.net/index.php/portfolio/)

#### v1.8.3 2010/5/20

 * LOCALISATION: Polish translation courtesy of [Pawel, Siedlecki Portal Informacyjnie Najlepszy](http://www.spin.siedlce.pl)
 * LOCALISATION: German translation courtesy of [Meini, Utech Computer Solutions](http://utechworld.com)

#### v1.8.2 2010/5/14

Dear Non-English Exclude Pages Users,

This release includes the facility for Exclude Pages to be translated into languages
other than English. Please [contact me](http://www.simonwheatley.co.uk/contact-me/)
if you want to translate Exclude Pages into your language.

Sorry it took so long.

Best regards,

Simon

 * DROPPED SUPPORT FOR WORDPRESS VERSIONS PRIOR TO VERSION 2.7
 * BUGFIX: Everything was reporting that it was excluded by an ancestor for some
   reason. Crazy. Fixed now.
 * LOCALISATION: Added POT file! Woo hoo!

#### v1.8.1 2010/4/19

 * BUGFIX: Check for existence of parent object before attempting to use it. (Thanks
   to Robert Kosara for the bug report.)

#### v1.8 2009/10/27

 * BUGFIX: PHP 5.3 doesn’t like the fact that parameters marked as passed by reference
   as passed as value. Params now not marked as passed by ref.

#### v1.7 2009/7/29

 * ENHANCEMENT: You can now turn the Exclude Pages functionality off in the admin
   area through use of a filter (this is mainly of advantage to other plugin and
   theme author).

#### v1.6 2009/6/8

 * ENHANCEMENT: You can now turn the Exclude Pages functionality off before showing
   navigation which you want to be comprehensive (and show pages you’ve normally
   hidden). This is done with the new `<?php pause_exclude_pages(); ?>` and `<?php
   resume_exclude_pages(); ?>` templates tags.

#### v1.51 2009/4/23

 * FIX: Was throwing an error when $pages turned out not to be an array. Thanks 
   to (Sandra)[http://www.vinyltangerine.com/] for reporting this.

#### v1.5 2008/11/03

 * ENHANCEMENT: Now compatible with WP 2.7-beta1
 * DOCS: Added a list of incompatible plugins
 * DOCS: Added a list of incompatible themes

#### v1.4 2008/01/02

 * ENHANCEMENT: Now compatible with WP 2.5
 * FIX: Pages are also excluded from the “Front page displays:” > “Posts page:” 
   admin menu. (Reported by Ed Foley) This plugin now checks if it’s within the 
   admin area, and does nothing if it is.

#### v1.3 2008/01/02

 * FIXED: Descendant (e.g. child) pages were only being checked to a depth of 1 
   generation.
 * FIXED: The link to visit the hidden ancestor page from an affected descendant
   page was hard-coded to my development blog URL. ([Reported by webdragon777](https://wordpress.org/support/topic/147689?replies=1#post-662909))
 * FIXED: Stripped out some stray error logging code.

#### v1.2 2007/11/21

 * ENHANCEMENT: Child pages of an excluded page are now also hidden. There is also
   a warning message in the edit screen for any child page with a hidden ancestor,
   informing the person editing that the page is effectively hidden; a link is provided
   to edit the ancestor affecting the child page.

#### v1.1 2007/11/10

 * FIXED: Pages not created manually using “Write Page” were always excluded from
   the navigation, meaning the admin has to edit the page to manually include them.
   Pages created by other plugins are not always included in the navigation, if 
   you want to exclude them (a less common scenario) you have to edit them and uncheck
   the box. ([Reported by Nudnik](https://wordpress.org/support/topic/140017))

## Meta

 *  Version **1.92**
 *  Last updated **8 years ago**
 *  Active installations **30,000+**
 *  WordPress version ** 2.2.3 or higher **
 *  Tested up to **3.4.2**
 *  Language
 * [English (US)](https://wordpress.org/plugins/exclude-pages/)
 * Tags
 * [exclude pages](https://bre.wordpress.org/plugins/tags/exclude-pages/)[get_pages](https://bre.wordpress.org/plugins/tags/get_pages/)
   [hide pages](https://bre.wordpress.org/plugins/tags/hide-pages/)[menu](https://bre.wordpress.org/plugins/tags/menu/)
   [navigation](https://bre.wordpress.org/plugins/tags/navigation/)
 *  [Advanced View](https://bre.wordpress.org/plugins/exclude-pages/advanced/)

## Ratings

 4.9 out of 5 stars.

 *  [  44 5-star reviews     ](https://wordpress.org/support/plugin/exclude-pages/reviews/?filter=5)
 *  [  1 4-star review     ](https://wordpress.org/support/plugin/exclude-pages/reviews/?filter=4)
 *  [  1 3-star review     ](https://wordpress.org/support/plugin/exclude-pages/reviews/?filter=3)
 *  [  0 2-star reviews     ](https://wordpress.org/support/plugin/exclude-pages/reviews/?filter=2)
 *  [  1 1-star review     ](https://wordpress.org/support/plugin/exclude-pages/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/exclude-pages/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/exclude-pages/reviews/)

## Contributors

 *   [ Simon Wheatley ](https://profiles.wordpress.org/simonwheatley/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/exclude-pages/)

## Donate

Would you like to support the advancement of this plugin?

 [ Donate to this plugin ](http://www.simonwheatley.co.uk/wordpress/)