getting content from main domain to sub-domain using category and WP_Query

What you can do is to set up a pre_get_posts() filter in the subdomains’ theme functions.php file to restrict posts to the desired category… function my_subdomain_category( $query ) { if ( $query->is_main_query() ) { $query->set( ‘cat’, ‘123’ ); // use the categoryID for space or products } } add_action( ‘pre_get_posts’, ‘my_subdomain_category’ );

Overwriting posts_per_page in new WP_Query

In the dump of your $args above, nopaging is set to 1 which disables pagination (equivalent to posts_per_page = -1). Try setting this to false and see if it fixes your issue. You can then look into why it’s being set.

List only posts from specific category on category page

You are complicating everything with a custom query. You should never ever replace the main query with a custom one on the home page or any type of archive page, this breaks page functionalities as you have seen. You should take your time and read this post I have done on this particular issue You … Read more

WP_Query Group by Author and Order each group DESC

EDIT 2 My idea in edit one did not work, so I scrapped it. This edit I have sorted the returned array using a foreach loop to sort the posts according to date under the specific author, and the author on top has the newest posts. The code below is tested and working, so you … Read more