In this way you add in “exclude” parameter like this
‘exclude’ => ”, // here add this page id you don’t show in listing.
‘exclude’ => ‘2,4’, like this
If you want only child pages you will use get_page_children() function.
Please see this link for reference
http://codex.wordpress.org/Function_Reference/get_page_children
Related Posts:
- How to show a dynamic_sidebar if main content content’s height is > a set amount?
- if statement with is_active_sidebar()
- Why the dynamic_sidebar() call is putted into an ul tag?
- Sidebar doesnt get updated?
- WordPress Themes and PHP unit
- Need help setting default setting value for radio button in theme customizer
- Remove Customize Background and Header from Appearance admin menu without CSS or JS
- Dynamically change feature image in customiser
- Design view breaking on Pages
- Adjust the results quantity for Search Results page pagination
- display most popular tags in two columns
- How can I loop into two different DIVS without repeating the DIVs
- Removing unnecessary wordpress files
- WordPress loop specific thumbnail size
- Passing array in add_option()
- Is it possible to use the featured image of a page as a css background without inlining?
- How do I translate this string – PHP syntax question
- Site Health : An active PHP session was detected
- How to make thumbnail image fit into a div where image dimentions are completely different?
- Why WordPress architecture is not pure object oriented and it don’t use MVC pattern? [closed]
- How to display recent posts on home page with custom HTML
- using add_action for a header hook that has an additional parameter
- How to create a linked tag list in my sidebar
- write custom woocommerce templates and forms
- Using a `Template Parts` folder instead of an `Includes` folder in a Custom WordPress Theme
- Set the checkbox as checked by default at options page
- How do I add custom bulk actions to multiple custom post types?
- what is the best practice to add new field to an api route
- Grab posts by multiple categories
- populate form fields in a loop with ajax
- Error in custom php function doesn’t exist
- Customizer: active_callback and sanitize_callback incompatibility?
- Child page menu in sidebar
- Recent Posts Not Showing Only On A Specific Category Page [closed]
- How to disable controls in theme customizer?
- How to remove woocommerce_breadcrumb() from do_action( ‘woocommerce_before_main_content’ ); [closed]
- What does this mean in wordpress? Easy question
- How to determine if the sidebar is empty? Or not active?
- Show About and Contact Us page when they’re clicked in the top menu.
- Is There A Way To Make Theme Files Accept Shortcodes?
- WordPress Customizer Default Image
- Theme’s Options Page included with require_once *.php in functions.php not visible anymore
- How to show an entire post content and not also the excerpt?
- WordPress import media error
- Why is an array created in a function hooked to customize register populated when customizer is loaded but not when the front-end is loaded?
- Hide Heading if ACF Field is empty
- How to add the sidebar to all the pages except the home page? [closed]
- Header not properly displaying on archive.php
- How do I get the content excerpt of the recent post?
- Save Custom CSS file in the upload folder dynamically?
- Validate and Sanitize WP REST API Request using WP JSON Schema?
- Getting posts to exclude from array
- home.php show blog posts as grid view
- Custom post type permalinks do not appear using the link functions
- Is there a name for trivial WP PHP files like functions.php, archive php entry.php, page.php and so forth?
- Removing “Powered by” footer using child theme PHP [closed]
- Using bloginfo and divs inside a php file
- Unable to access WordPress functions from functions.php
- Get css class of menu item in custom menu structure
- How to organize functions.php content
- Why when I create a new post I found 2 record related to this post into the posts database table?
- Search page results conflicting logic – Search result caching?
- pass html code to worpdress
- Commas in Tag Cloud
- Don’t display a sidebar widget when on a specific page
- security concerns if using html data-* attribute for l10n?
- For some time, some of my pages do not display the content anymore. Any idea where this could be coming from?
- Dynamically switch file in get_template_directory_uri() | Function [closed]
- How do you create a custom category widget that you can style?
- How to extend SelectControl with data from my theme
- How to change basename url for wp-admin?
- excep tonly one css, don’t load any css
- url not using query string no longer working
- Not able to remove caption shortcode from the content
- How to use wp_get_attachment_image or wp_get_attachment_image_src instead of $instance[‘single_feature_image_uri’]
- Weird fonts showing which are coming from database
- require get_template_directory() . ‘path/to-my/file.php’ BREAKS customize > themes functionality
- How to have different headers.php files based on the display page
- add custom link to gallery images
- Proper use of Output Buffer for a whole php clas
- How to properly escape in ternary operators – Wp Coding Standards?
- CSS loading as empty file in Custom Theme
- What image is this pulling?
- How can I customize a WordPress theme before it’s downloaded?
- Rotating Header Images
- Adding a sidebar to wp-login.php
- Trying send mail from Theme page
- Save the outputted image into the Media Library, with a different filename and extension
- WP Knowledge Base Theme bug – Subcategories and Articles, Need to change WP_Query
- How to style this wp_list_pages markup
- WordPress causing all code to be displayed on line 1. Receiving multiple errors after cleaning cookies and cache
- Adding code to the function file
- Shortcode working in page.php but not in category.php in wordpress
- Adding a Sub Menu Options Page WP Backend Menu. Whats wrong with my code?
- How can a ‘scripts’ directory be hooked into wp_head();?
- WP and Laravel integration (Updated) [closed]
- paginate_links() returns NULL instead of the pagination links, but pagination is actually happening
- PHP warning: Undefined array key 2 in feed.php
- How to hide header and footer from page template
- Sidebars panel in customizer