1st Level Page with No Children

To expand upon my comment: Top-level page? (q.1) global $post; $x = get_ancestors( $post->ID, ‘page’ ); if( ! $x ) { // there are no ancestors, therefore this is a top-level page } Childless page? (q.2) global $post; $args = array( ‘post_parent’ => $post->ID, ‘post_type’ => ‘page’, ); $x = get_children( $args ); if( ! … Read more

Children Shortcodes?

This is possible, but you can only nest one level down, after that the shortcode regexp parser flips out. So your example would be okay, but [item1] would not be able to contain even more nested shortcodes. To enable nesting, just go ahead and do: add_shortcode(‘data’, function($attributes, $content=””) { return do_shortcode($content); } Relevant article: http://www.sitepoint.com/wordpress-nested-shortcodes/

Get count for all terms inside a parent term

I don’t know why that code didn’t work for you. I copy that code and it work exactly as I expected. You should double check your case, did you unset $args variable before, or you can use another name ($agrs2 for example). Another problem in you question is: if pad_counts doesn’t work, you will get … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)