Viewing 1 to 6 of 6 items
Tag Archives: exclude

Remove a category from the front-page.php

The correct way to do this is to make use of pre_get_posts which change the query vars just before the main query is executed. Here is an example from the codex to exclude categories from the home page/blog page. For a full list of available parameters and values that you can use with pre_get_posts, visit  Full Article…

0

Filter Duplicate Posts in the Loop

As seen on the great WP Engineer website:¬†http://wpengineer.com/1719/filter-duplicate-posts-in-the-loop/?codekitCB=400689137.981452 As the question arises quite often I’d like to show how I make sure that the content presented, which were output in a loop, not showed up again in a second loop. WordPress identifies posts and pages via ID, which are created in the database and who  Full Article…

0

Exclude posts or pages from search results

Would you like to be able to control which post or pages must be exclued from searches on your WordPress blog? If yes, this article will probably help you a lot. To achieve this, just simply paste the following code on the functions.php file from your theme. In this example, your wordpress posts with IDs  Full Article…

0

Exclude pages in a section (exclude_tree)

All you have to do is include this block of code in your template the same way you would the regular <?php wp_list_pages();?> tag. Page IDs that you would normally pass to exclude_tree go in the first line):

0