The tag has no usage guidance.

learn more… | top users | synonyms

0
votes
0answers
26 views

How to get post count including nested categories

I am traversing through categories using function like this function hierarchical_term_tree($category = 0) { $r = ''; $args = array( 'parent' => $category, ); $next = ...
1
vote
1answer
70 views

Get the last month with posts using a recursive function…

There is probably another way but I would like to understand why this code returns null... I only have posts in october and here's the recursive function: function last_post( $month,$year ) { $...
0
votes
1answer
50 views

Is there any good reason for two CSS files to @import each other?

I'm working on some critical style revisions for a client's WordPress site that was designed by another team. The CSS seems to be a tangled mess. One of the idiosyncrasies I've found is that the ...
0
votes
2answers
3k views

How to show only parents subpages of current page item in vertical menu?

I just can't find a way to make it possible to show only current parent items down to current page item in a vertical menu the "wordpress way". What I want to achieve is the following dynamic ...
1
vote
1answer
88 views

Pushing stored procedure to a multisite database in WordPress

I am given a WordPress multisite and need to extract information from the site. I have written a stored procedure that recursively builds a tree relationship for posts of a certain kind. Now I am ...
2
votes
3answers
1k views

Why am I getting an infinite loop with have_posts?

I have the following code, which causes an infinite loop for some reason. Can anybody explain what's going on please? Thanks! <?php $flagged_stores = new WP_Query( array ( 'post_type' => '...
1
vote
3answers
704 views

A function like is_page() but returns true if on any sub page of given page

In my header I use this code: if(is_page("stores")) { // Do something } I run some code if on the page stores but what I want to do is run that code if the page is stores or any page that is a ...