Skip to content

Instantly share code, notes, and snippets.

View mikeoberdick's full-sized avatar

Mike Oberdick mikeoberdick

View GitHub Profile
@mikeoberdick
mikeoberdick / style.css
Last active February 11, 2023 12:29 — forked from djrmom/readme.txt
facetwp radio styled as buttons
.facetwp-radio {
background-image: none;
background-color: gray;
padding: 5px;
display: inline-block;
margin: 5px;
}
.facetwp-radio.checked {
background-image: none;
@mikeoberdick
mikeoberdick / functions.php
Created March 19, 2019 23:56 — forked from srikat/functions.php
Changing the posts per page on first page without breaking pagination in WordPress. https://sridharkatakam.com/changing-posts-per-page-first-page-without-breaking-pagination-wordpress/
add_action( 'pre_get_posts', 'sk_query_offset', 1 );
function sk_query_offset( &$query ) {
// Before anything else, make sure this is the right query...
if ( ! ( $query->is_home() || is_main_query() ) ) {
return;
}
// First, define your desired offset...
$offset = -1;