Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?php
add_filter('posts_request', function ($request, $query){
if( ($query->is_main_query() && $query->is_front_page()) && !$query->is_admin) {
return false;
} else {
return $request;
}
}, 10, 2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.