I'm running a list of pages in my header using the following code:
<?php wp_list_pages('title_li=&depth=1'); ?>
I want to exclude child pages from this list. I've tried several things, but I'm just not getting it.
Any advice? Answers? Thanks in advance,
http://codex.wordpress.org/Template_Tags/wp_list_pages#Exclude_Pages_from_List
<?php wp_list_pages('exclude=17,38' ); ?>
Where 17 and 38 are the ID's of the pages you want to exclude.
I'm thinking the poster is trying to exclude the child pages in general.
Have to admit that depth=1 should work.
What is happening? Is it displaying everything?
Some templates really mess up if you have child pages - is that what you mean, Bill?
I usually add stuff to the stylesheet to make 'em drop-downs.
Actually, I have since discovered that in the template I am using right now, the child pages are not displaying. Which is good, because I didn't want them to, and I was under the impression they would. I would LOVE to insert code to make them show a drop down upon rollover. Any examples? I spent abut an hour going through the themes on my site trying to find one.
It's a bit of tricky css to wrap your head around at first.
http://www.cssplay.co.uk/menus/dd_valid.html
Mostly what I've been doing lately is find code that works for the basic theme I start with, then copy/paste it in the rest & tweak.
No suckerfish plugin, no javascript. :D
I looks NICE. I'll try adapting.
OK, I added the above code to the style sheet and there's no change whatsoever.
Coming to the conclusion this us above my pay grade and I am moving on .