This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* To display entries from a Custom Post Type on site's front page in a 3-column responsive grid. | |
* URL: http://sridharkatakam.com/front-page-template-to-show-cpt-entries-in-a-3-column-grid-in-genesis/ | |
*/ | |
remove_action( 'genesis_loop', 'genesis_do_loop' ); | |
add_action( 'genesis_loop', 'sk_do_loop' ); | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ----------------------------------------------------------------- | |
# .gitignore for WordPress @salcode | |
# ver 20180808 | |
# | |
# From the root of your project run | |
# curl -O https://gist.githubusercontent.com/salcode/b515f520d3f8207ecd04/raw/.gitignore | |
# to download this file | |
# | |
# By default all files are ignored. You'll need to whitelist | |
# any mu-plugins, plugins, or themes you want to include in the repo. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// GENESIS get featured image. | |
// 1. Sets the featured image. | |
// 2. If no featured image then get image from category. | |
// 3. If no category image then get the first post image. | |
// 4. If no post image or category image then set a fallback image. | |
// Add to your functions file. | |
// Resources | |
// https://wordpress.org/support/topic/make-first-image-in-post-featured-if-no-featured-is-set?replies=9 | |
// http://wpsites.net/web-design/add-default-featured-image-for-each-post-in-a-category/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Converter; | |
use WebPConvert\WebPConvert; | |
class Converter | |
{ | |
public $lazy = false; | |
public function __construct($lazy = false) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Filter to customize FacetWP, should be pasted in FacetWP's "Custom Hooks" plugin | |
* | |
* Made for a "location" FacetWP autocomplete filter that uses a taxonomy "location" | |
* consisting of parent county terms and child city terms | |
* | |
* When indexing, for every post, for the location taxonomy filter, | |
* Check to see if it has any location taxonomy set | |
* Check to see if selected location taxonomy has children (i.e. selected county has cities) | |
* Create a new index row for each child city |
OlderNewer