Display Posts by Modification Date in GeneratePress
-
On My Previous Theme, I used that function, but I don’t know how to do it in generate press
So Can you help me to do this with generatepress theme?
Previously I was using WordPress Filter for this//function to modify default WordPress query function wpb_custom_query( $query ) { if( $query->is_main_query() && ! is_admin() && $query->is_home() ) { $query->set( 'orderby', 'modified' ); $query->set( 'order', 'DESC' ); } } // Hook custom query function to the pre_get_posts add_action( 'pre_get_posts', 'wpb_custom_query' );
I was using this filter, How can I do this in generate press, and from where can i get generatpress child theme.
Thanks
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Display Posts by Modification Date in GeneratePress’ is closed to new replies.