html sitemap via recursive function
The “memory exhausted” error in question happened because of this part in your function: ‘parent’ => $next_page -> post_parent, which should actually be ‘parent’ => $next_page -> ID (or I’d omit the unnecessary spaces, i.e. I’d use ‘parent’ => $next_page->ID). And the error can be illustrated like so: $cur_page = get_post( 123 ); // assume … Read more