The tag has no wiki summary.

learn more… | top users | synonyms

0
votes
1answer
37 views

Nested custom post types templating

I have multiple custom post types which I nested thanks to a plugin and post I found. I have a custom post type 'landen' ( which should be the parent post type ) and a child post type 'rondreizen', ...
0
votes
1answer
33 views

Permalink for PDF of article

I'm trying to learn if this is possible, and how I might go about implementing it. Our site is a scientific journal, and our published articles follow this permalink structure: ...
0
votes
1answer
57 views

If product is in sub-category show code

This code works with categories but not with child sub-categories. How can I make it work a child category that is not in the url (slug)? global $post; $terms = wp_get_post_terms( $post->ID, ...
0
votes
0answers
34 views

Force Category Sidebar To Show Just One Level Sub-category?

Here is an example of normal categories displayed in the sidebar: - MAIN 1 -- Sub One --- Sub Sub One --- Sub Sub Two -- Sub Two - Main 2 -- Sub Two This is the default structure. Here is ...
0
votes
1answer
265 views

Display Categories or Subcategories with name & description in category.php in wordpress

I have the following issue for my customer. Can some suggest a possible solution to this issue? This website has Categories & Subcategories Cat1 -Subcat1 -Subcat2 -Subcat3 Cat2 -Subcat1 ...
0
votes
1answer
230 views

List child categories from parent category on custom taxonomy page

I making some updates to a theme I'm currently working on. I've moved a bunch of categories that have custom post items under them into a parent category that's all within a custom taxonomy. e.g.: ...
0
votes
1answer
18 views

Children Shortcodes?

I started creating WordPress plugins a few weeks ago, and I would like to know if it's possible to somehow "embed" shortcodes in some others. Basically what I want to do is create a table or a list, ...
7
votes
4answers
243 views

How can I hide children of draft pages using wp_list_pages()?

I'm displaying a simple sitemap with wp_list_pages(); $args = array( 'sort_column' => 'menu_order', 'title_li' => '', 'post_status' => 'publish' ); wp_list_pages( $args ); ...
1
vote
1answer
150 views

Show only first children level of current category?

I wish to display only first level of subcategories on current category page (if any). I tried this code: <?php $args=array( 'child_of' => $cat-id, ...
0
votes
1answer
24 views

1st Level Page with No Children

I have a website (http://sfa.uconn.edu/) that displays left menu with a list of child pages on any parent page (and its children), like this: However, I would like to hide this functionality from ...
2
votes
1answer
308 views

Check if a post is in any child category of a parent category

In a site I'm developing, I have the following category structure: * movies (parent) * thriller (child) * comedy (child) * drama (child) The current post is in the comedy category. The ...
0
votes
1answer
122 views

How to customize taxonomy archive template files for subterms?

I have a taxonomy called "location" where I have the term "Asia" and the sub-term "Thailand". Now I created the taxonomy archive template file according to the Wordpress Codex, which is working in ...
-1
votes
2answers
87 views

How to retrieve posts from parent category, splitting them per children when displayed?

I have a Wordpress database with three categories: ID 3 : Europe ID 4 : France (child of 3) ID 5 : Paris (child of 4) I now need to display all posts under their respective category, like this: ...
1
vote
0answers
13 views

'Create New Child Post' from Parent Post using a button - not using Attribute drop-down

I have a custom post type "my_custom_post_type" which contains posts using a grandparent > parent > child hierarchy. I am currently using the 'Attribute' drop down to assign a new post to a parent ...
1
vote
2answers
387 views

Showing current subcategory

I have problem. <?php query_posts('category_name=events&posts_per_page=2&offset=1'); ?> <?php while (have_posts()) : the_post(); ?> <div> <?php $children = ...
0
votes
2answers
213 views

How to make child categories recognize parent's template displays

I'm using the Default Post Type post for various purposes. To sort them I'm using different categories. And I'm designing different category layout using the slug preference, like: category-book.php, ...
0
votes
2answers
34 views

How to print the current post depth as update notification?

I need to find a simple if-condition to print the current post-depth for parents as an update notification. The following code in the functions.php is not working, it is resulting in "0" for all ...
0
votes
1answer
34 views

Displaying direct children of other pages on homepage

I am trying to display the DIRECT children of another page on the homepage but I can't seem to get it working it just shows all of the page titles on the site.. It needs to be within a wp_query as I ...
0
votes
0answers
61 views

Automatically add another subpost of the same parent when a subpost is saved

I figured it out how to add one subpost when a post is saved. But now I need to know how I can get another subpost of the same parent when a subpost is saved. Could anybody help me out? This is what ...
1
vote
3answers
132 views

Multiple Conditions for Child Page Title

I've been trying to work with Conditional Tags and cannot wrap my head around this problem. PHP novice here. On sub-pages I need to display the parent page title as well as the page title. I have it ...
0
votes
1answer
84 views

“Static” Child Menu with Accordian

I'm looking to create a child menu and none of the examples in the Wordpress codex seem to do what I'm trying to create. I have a main horizontal nav bar, which is fine. When clicking on a top-level ...
0
votes
0answers
376 views

How to show only subcategories in parent category not parent category?

I just want to show only subcategories of specific parent category on parent category page. I have 1 parent category videos and 3 child categories art,funny,and technology of that parent. I didn't ...
0
votes
1answer
81 views

Need a conditional to test if title of parent page matches title of child page

In my main loop, I need to incorporate proper html markup into a conditional to test if title of parent page matches title of child page and do (or do not) display certain content. Default might be ...
0
votes
1answer
58 views

How do I sort post listing by child post count?

I have two custom post types called questions and answers. The questions list includes a custom column which displays a count of the answers for each question. I need to be able to sort the listing ...
0
votes
1answer
36 views

Children categories not shown in dashboard

First of all: it's a strange behavior, but it works. 1) I'm working on a script, so i require the wp-load.php and after that i operate; 2) The scripts creates some categories using wp_insert_term in ...
0
votes
2answers
256 views

Get ID of child from child slug, while knowing parent ID

I have a hierarchy that I need to get data from. It's the child (by slug name) that I need to get while already having knowledge of the parents. Highest Known Parent Page (slug : 'parent') |_ Child 1 ...
0
votes
1answer
79 views

Differentiate Parent & Child of Custom Taxonomy

I use Custom Taxonomy "Artists" to differentiate between "Albums" (Parent Taxonomy) and "Albums" (belonging to an Artist, Child Taxonomy). I am showing my taxonomy on posts for users to see which ...
0
votes
2answers
222 views

List of child custom post types lists all custom post types

Several of my pages have some "posts" of custom post types as child posts. On these pages I want to list all of the child posts. Therefore I have this code: <?php $page_id = ...
0
votes
1answer
186 views

List post from current taxonomy children

I have a custom post type and a taxonomy with children, with a template file named taxonomy-productcategories.php. On this i want to list all children with their posts. Child taxonomy 1 Child ...
0
votes
1answer
83 views

Don't repeat posts from children in parent taxonomy query

I have a query on a page and I want to prevent it from returning posts in the parent term that have one of the child terms of the parent. For example: Parent 1 Child 1 Post 1 Post 2 NOT Parent ...
1
vote
2answers
232 views

get_term_children returns WP_Error for custom taxonomy

What I'm working on is a ajax based dropdown option form which returns child terms based on the option selected. When the option is selected, a function is fired using onchange, where the script ...
0
votes
1answer
320 views

Custom Post Type children and grand-children in one list

So, here is the story: i made a product catalogue with 3 custom post types: - Product - Filegroup (Child of Product) - File (Child of Filegroup) When on product page it should show a ...
0
votes
0answers
30 views

list first post of Child Category on Category page

This may be a bit overcomplicated but this is exactly what my client is asking for and if there is anyway to accomplish this task it would be much appreciated. I've found lots of examples of just ...
1
vote
2answers
835 views

Wordpress Child Category Display All Posts

I am creating a Wordpress page where all my posts in the child categories of team are displayed in a grid. I got this working with the below code. The formatting and general layout is great however it ...
-1
votes
2answers
152 views

query only direct child and sub-terms of a current term archive

i'm using woocommerce on my theme, and it comes with a proudct_cat term as a defualt catagory on the shop proudct. I need to show on every proudct_cat archive its direct child and the sub-tems, but ...
0
votes
2answers
99 views

Page to output sub-pages (children)

I want to output all sub-pages of a particular page in a neat ul li list. Including: featured image, title, and first 50 characters of page content. I'm very new to Wordpress, I've tried reading ...
0
votes
0answers
33 views

How to include child terms within parent?

I have the following for a specific term ID: <?php if (!is_tax( 'listing_category', '542' )) { ?> test1 <?php else: ?> test2 <?php } else { ?> This works great for making ...
0
votes
3answers
731 views

Taxonomy Drill-Down / Plugin Help - hierarchical queries within plugin?

I hope this question doesn't make me look too stupid! I am using a plugin called 'Query Multiple Taxonomies' -- it's a fantastic plugin and is written extraordinarily well. ...
0
votes
2answers
100 views

Get all children titles of a page as a link to them

I want to pull all the children titles of certain page and put them as a link. This is what i got so far: $my_wp_query = new WP_Query(); $all_wp_pages = ...
-2
votes
1answer
113 views

How can I structure my pseudo footer nav code with wordpress codex code?

I'm building my first fully custom wordpress theme, and I'm starting to pull hairs out while trying to write the dynamic footer code! I've tried a bunch of codex this and codex that but can't seem to ...
0
votes
1answer
52 views

List CPT by menu_order with children right after parent

I registered a custom post type drawer where my posts are ordered using menu_order. Each drawer could be a child of another drawer, on a multiple depth (parent > child > child of child > child of ...
0
votes
1answer
177 views

Better wordpress attachment query then this

I have a site with more then 10.000 posts and images, its classipress site. I need somehow to show all images from posts that are on pending status, and who havent expired(post meta). This is the code ...
0
votes
1answer
205 views

how to display all images from their siblings/ from same parent?

I need to know how to display all images from the current page siblings. for eg. I got two parents (Hockey and football) with children. In all this children I got one or several images attached (I've ...
10
votes
3answers
4k views

Custom Nav walker display current menu item children, or siblings on no children

I've been messing around / searching for hours and still can't get this to work, so i'm finally giving in and asking for some help. I'm trying to write a custom walker that shows only the current ...
0
votes
2answers
1k views

Menu Arrow for Child Element

I have a menu for a website I am designing and there are parent and child elements...I was wondering if there was someway I could add an arrow to my navigation if the parent has a child element? My ...
0
votes
1answer
411 views

Check is category parent with ids from the childs - get_term_children

I have a hierarchical category list, like: A (Parent Category) - B (Child Category) - C (Child Category) - D (Child Category) B (Parent Category) - E (Child Category) - F (Child Category) ...
0
votes
1answer
258 views

How to use wp_list_pages on a grandparent page

I am using wp_list_pages to show the page structure on a website. For instance, if I use this code, it will show me the complete child / grandparent heirarchy of the current page the user is on: ...
0
votes
1answer
199 views

Set order of returned items in the WP_Query() class/function

I have this function which gives me IDs and titles of all child pages of a given parent ID. function getPageChildren($page_id) { $my_wp_query = new WP_Query(); $all_wp_pages = ...
0
votes
2answers
400 views

Child Category Image

I have some code that display's the titles of my child category posts on one of my pages: <?php $parent = get_cat_ID("photos"); $cats = get_categories('child_of='.$parent); foreach ...
0
votes
1answer
633 views

How to create drop down for child categories of current taxonomy being viewed?

I need to know how can I get the child/grandchild terms of the current taxonomy being viewed, and put it into a drop down so that I can add values to the options. I am currently using this code to ...