This function displays a list of WordPress Pages as links. It is often used to customize the Sidebar or Header, but may be used in other Templates as well.
0
votes
1answer
14 views
Listing current pages subp page in list items in the sidebar
I'm wanting to list my current page's child pages as list items in the sidebar of my wordpress site.
So far I've been referencing the http://codex.wordpress.org/Function_Reference/wp_list_pages
I'm ...
0
votes
1answer
26 views
Hide Parent if No Children
The codex provides a way to display the children and parent page for use as a sub-menu. However, this code displays the parent page in the list even when the parent has no children. How can I modify ...
0
votes
1answer
18 views
Add Parent to Subpage List
Below is the best code I could find for producing a list of subpages and the parent page. However, it only shows the parent page while on the subpages. How do I get this to display the parent page ...
0
votes
0answers
13 views
List custom post type as children of page in wp_list_pages
I've got a WP site, with a custom post type set for team members (called 'people').
In the site page hierarchy, I have:
About
-> Team
Is there a way so that all entries for the team members, are ...
0
votes
2answers
41 views
Add Parent to List of Subpages
This code works well to display child pages of the parent page while viewing both the parent page and child page. It doesn't apply the current_page_item CSS class to the parent while viewing it (and ...
2
votes
1answer
38 views
Test if page is child and has children, if so echo child pages also on grandchild pages
I am trying to show a sub-menu of child-pages only on level 2 pages (who have a parent) and if they have children. I am using the code below (made from several snippets I found), it works fine on ...
0
votes
2answers
39 views
Add ID to target navigation link
I am using the following code for a navigation bar on a WordPress website:
<?php wp_list_pages("title_li="); ?>
Which currently spits out some links that look like:
<a ...
0
votes
1answer
14 views
How to make in post Parent page children page list nummbered
Parent page
veggies
Its children pages are
carrots
peas
potato
How to put in post numbered list of Parent page?
Maybe better how to make same list to be ordered by date posted so some ...
0
votes
2answers
22 views
alternating classes on wp_list_pages
I'm trying to have alternating classes on the list created by wp_list_pages.
Currently I have extended the Walker_page class updating the start_el function as follows:
class Sidebar_walker extends ...
0
votes
0answers
36 views
Display a custom post type list by taxonomy term
I need to show a list of custom post type classified by terms. The idea is something like this:
Service list:
<ul>
<li>
<a href="#">Webdesign (taxonomy term)</a>
...
0
votes
1answer
55 views
Custom wp_list_pages() function
I have following code in my .php file:
$my_pages = wp_list_pages("title_li=&child_of=".$my_id."&echo=0");
Then I create an <ul>
<ul>
<?php echo $my_pages; ?>
...
0
votes
0answers
39 views
Check if meta_key exists in wp_list_pages
I have added a custom field (using Advanced Custom Fields plugin) to a page allowing you to show/hide it with a simple checkbox, i want to filter out these pages if a user is not logged in so i am ...
0
votes
1answer
38 views
only display Pages which have children
Here is my website structure(wordpress pages)
- HOME -
- Tutorial -
+ PHP Tutorial +
+ Photoshop Tutorial +
+ Css Tutorial +
+ HTML Tutroial +
- news -
+ November
+ ...
0
votes
1answer
81 views
Display all submenus
For a custom jquery menu I'd like to show all submenus and hide / show each on demand. However my problem is to show all submenus in the first place.
As of now I am managing the first level through ...
0
votes
1answer
39 views
Showing Custom Menus in the sidebar
I want to get custom menu in my top level page and the sub pages which are not child of the top level pages.
I got many examples using wp_list_pages but it requires the sub pages should be the child ...
0
votes
1answer
59 views
add a.parent in wp_list_pages
In relation to question posted here, is it possible to have an output to have something like this instead? where class="parent" is applied to the hyperlink?
<ul>
<li><a ...
0
votes
1answer
35 views
Show menu on page with all sub-pages and sub-sub-pages of that page
I am trying to create a menu, with sub-pages and sub-sub-pages of a current page.
I want the menu to work as a dropdown, where the sub-sub-pages for a sub-pages are shown when the user clicks the ...
0
votes
1answer
25 views
WordPress function breaks widget's markup?
Here's a standard function creating widget, it displays Widget's title and echoes "test" below it:
function widget( $args, $instance ) {
extract( $args );
$title = ...
0
votes
0answers
85 views
wp_list_pages - Using a Walker to customize output order
I'm using wp_list_pages to create a navigation menu. I've run into a challenge with the menu order, though, and I am trying to figure out a way to take more control over the order of the menu.
Is it ...
0
votes
1answer
32 views
remove auto generated pages from the menu?
I have a simple function that adds a couple of pages to the users website when they activate my plugin. Actually there are many plugins out there that generate custom pages for the user, plugins like ...
0
votes
1answer
360 views
Change ul class=“children” for wp_list_pages?
Hello I'm using this code to print a list of Pages and Subpages:
<ul>
<?php wp_list_pages('title_li=&depth=2&child_of='); ?>
</ul>
It outputs:
<ul>
...
0
votes
1answer
58 views
Extra title output with this function wp_list_pages
here is the code :
add_shortcode ('get_menu_child','get_menu_child');
function get_menu_child ($att) {
global $wp_query;
$thePostID = $wp_query->post->ID;
$output = ...
0
votes
1answer
86 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:
...
2
votes
1answer
118 views
dynamically limit depth of wp_list_pages
I guess that this should be an easy one but I haven't yet find the proper solution.
I want to limit the depth of wp_list_pages so as not to display the pages of the last level. So supposing that ...
0
votes
1answer
58 views
Listing Sub-Pages & Sub-Sub-Pages
So I don't really know why I am having so much trouble with this, it seems like functionality in wordpress that should be a bit easier to working with.
Anyhow I need to generate a menu system for a ...
0
votes
2answers
122 views
Handling complex multi-level architecture / menu for large site
I am trying to get feedback and ideas for solving an information architecture / content management problem using wordpress.
I have a large site ( 1,000+ pages, hundreds of posts ) made up of ...
0
votes
1answer
40 views
Inset image thumbnail from page into list
I currently have 10 child pages which each contain one main image and text.
I then have the main parent page, which acts as a 'contents page'.
I currently have this code on the main parent page... ...
0
votes
2answers
184 views
wp_list_pages: only show subpages on the parent page?
I'm using wp_list_pages('title_li=') on my site.
Some of my pages do have subpages, however I don't want to list them unitl I'm on an actual parent page that has subpages.
So imagine my front-page:
...
3
votes
0answers
165 views
Highlighting current item of custom post types' sub pages, listed by wp_list_pages
The below code is for listing the custom post types itself and its children in the sidebar.
The code works great but does not highlight the sub pages.
In functions.php:
...
0
votes
2answers
52 views
How to prevent custom walker from creating sub navigation for pages that are not relatives of the current page?
I have a custom walker that extends the Walker class. My code uses the Walker_Page class as it's base as it does pretty much everything else I want but I need to modify it a bit so that it behaves a ...
0
votes
2answers
57 views
list child pages as slug
I have a section on my site that needs a list of pages that are descendents of a particular ID. I need them listed on the child and grandchildren pages. But the page titles are too long, so I need to ...
0
votes
0answers
92 views
Get children with jQuery and wp_list_pages
I'm looking to create a button on a parent level page. If you click that button it runs through each of its children and performs some action via Ajax. The output is spit out back to the parent level ...
0
votes
1answer
85 views
Getting subpage of subpage - Custom posts
I have one page with custom posts. They are shown in one page with a list, you can choose one page and when you get to that page I need to show subpages of that page.
Here is so far ive made it, its ...
1
vote
1answer
95 views
List all-childpages on parent-page AND list child-pages on childpage itself but not the current one?
I have the following function that lists all Child-Pages of a page.
function show_subpages() {
global $post;
$subpages = wp_list_pages( array(
'echo' =>0,
...
-1
votes
1answer
59 views
Wrapping a function in html tag and return?
I am creating a shortcode. The shortcode will output a list of pages with the wp_list_pages() function. I am using the ('title_li') parameter and the list headline will be removed, because it is left ...
0
votes
1answer
65 views
Custom navigation bar via wp_list_pages is broken for blog roll
Pretty simple question.
I have the 'blog' on my site set via 'reading' to be the page 'blog' located at mysite.com/blog. /blog is hierarchical, in that it has children.
I have a custom side bar ...
1
vote
0answers
46 views
need help with existing code showing subpages
I am helping a friend make some changes to a wordpress theme. At the moment displaying subpages works only for one parent and its subpages (the one with id 31), but we want it to work for all pages ...
1
vote
1answer
128 views
Populate meta select box with child pages
I'm trying to populate a drop down select meta box with a list of child pages of that page.
I am using the wp_list_pages function to retrieve the list of child pages, no problem there.
The problem ...
0
votes
1answer
93 views
wp_list_pages() refuses to output posts
Someone help me understand why the following do not output anything:
wp_list_pages( 'post_type=post' )
wp_list_pages( 'post_type=event' )
Yet the following work as expected:
wp_list_pages( ...
0
votes
1answer
32 views
Is it possible to append an external html file to my wordpress navigation?
I'm trying to add a hardcoded 'megamenu' style dropdown div to my wordpress site.
The content of the div itself doesn't need to be administered via wordpress, it will all be hardcoded.
I don't want ...
1
vote
1answer
335 views
How to remove the HOME menu item
I am using wordpress 3.4.1.
I am mainly creating a static site and for that have created and arrnaged the pages, and wordpress has nicely created the pages in proper nav-menu format for me, which is ...
0
votes
3answers
182 views
Exclude current page in wp_list_pages
I'm using wp_list_pages() to display a menu of child pages.
The structure is nice and simple. Looks like this: http://cl.ly/image/0w1Q1q2D3D18
The menu works perfectly when on a child page: ...
0
votes
1answer
68 views
Second tier sidebar navigation
I'm trying to create a second level navigation in WordPress. I've found lots of examples, but none of them seem to do exactly what I want. This code below has me almost there, but I want an active ...
0
votes
1answer
366 views
List child pages by slug not ID?
I am looking to use the wp_list_pages function to show children pages of a specific page ID. I was able to do this easily, but now I found an issue with it. I am running a Wordpress network of sites ...
0
votes
1answer
75 views
Exclude pages by menu order
i have a "Default Page Generator" on theme activation i have created...
in that file i set 'menu_order' for each page.
i want to exclude pages with menu order bigger then 50 from the default ...
1
vote
1answer
72 views
List subpage of subpage
I've got a site with the following structure:
About
Page 1
Page 2
Page 3
Page 3.1
Page 3.2
So Page 1, Page 2,... are subpages of the About page. I would like to have a sidebar that lists the ...
1
vote
0answers
260 views
add alt and title attribute to wp_list_pages
For building my menu's, i'm using wp_list_pages. But i just found out that no alt/tittle attributes are rendered.
Unfortunately, with my php knowledge, i can't fix it. But it must me possible to get ...
0
votes
1answer
202 views
wp list pages using meta box value
I am using following meta boxes on services page but how i get page which on meta box value...
for example list all pages where service_type = 'web'
I am using following now...
<?php ...
0
votes
1answer
180 views
Add classes + taxonomy terms to wp_list_pages() output
I'm outputting a list of pages in my custom post type — a kind of tree — using wp_list_pages().
All's going well, except now I want to put some classes in the li's for styling. Even that's not going ...
0
votes
2answers
227 views
Sub Navigation in Sidebar
Testing Site: http://www.indysouthportdental.com.php5-1.ord1-1.websitetestlink.com
I only want to display the children of parent in the sidebar when viewing any pages within the parent.
For example, ...
