As in the title, I am looking for a way of outputting page ids instead of page names from wp_list_pages or other function for use in php.
The actual use I wish to put this to, is to auto-generate a list of child pages in the form “id1,id2,id3…” for use with the ‘exclude’ argument in another wp_list_pages.
Once wp_list_pages is passing id values, I know how to strip the
- etc., so that’s sorted, but the id problem is frustrating me.
Any light y’all can shed?
- The topic ‘Output page ids instead of names from wp_list_pages’ is closed to new replies.