WordPress Snippet
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
run.config: | |
engine: ruby | |
extra_packages: | |
- git | |
- nodejs | |
- nginx | |
- ImageMagick | |
- optipng | |
- jpegoptim | |
- gifsicle |
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 | |
/* | |
Plugin Name: Remove WPMU Notification Plugin Nag | |
Plugin URI: http://wp.me/p1Aj2B-6g | |
Description: WPMU started trying to force people that use plugins by their developers to install a Notification plugin by making a persistent notification bug the admins. This removes that annoying piece. | |
Version: 1.2 | |
Author: Trae Blain | |
Author URI: http://traeblain.com | |
License: GPL2 | |
*/ |
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
/////////////////////////////////////////////// | |
////// GRAVITY FORMS RESET STYLES ////// | |
/////////////////////////////////////////////// | |
// These styles are made in mind to be used with SCSS or LESS | |
// If you use these styles, you must go to the Gravity Forms settings in the WordPress back end and set Output CSS to No. | |
////----- Core Containers | |
.gform_heading, | |
.gform_body, |
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
// Changes Gravity Forms Ajax Spinner (next, back, submit) to a transparent image | |
// this allows you to target the css and create a pure css spinner like the one used below in the style.css file of this gist. | |
add_filter( 'gform_ajax_spinner_url', 'spinner_url', 10, 2 ); | |
function spinner_url( $image_src, $form ) { | |
return 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7'; // relative to you theme images folder | |
} |
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
<h1>Testing display of HTML elements</h1> | |
<h2>This is 2nd level heading</h2> | |
<p>This is a test paragraph.</p> | |
<h3>This is 3rd level heading</h3> | |
<p>This is a test paragraph.</p> | |
<h4>This is 4th level heading</h4> | |
<p>This is a test paragraph.</p> | |
<h5>This is 5th level heading</h5> | |
<p>This is a test paragraph.</p> |
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 | |
$post_type = 'post'; | |
// Get all the taxonomies for this post type | |
$taxonomies = get_object_taxonomies( (object) array( 'post_type' => $post_type ) ); | |
foreach( $taxonomies as $taxonomy ){ | |
// Gets every "category" (term) in this taxonomy to get the respective posts | |
$terms = get_terms( $taxonomy ); | |
foreach( $terms as $term ){ | |
echo $term->name; | |
} |
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 | |
$args = array( | |
'post_type' => 'location', | |
'posts_per_page' => -1, | |
'order' => 'ASC', | |
'orderby' => 'title', | |
'facetwp' => true, | |
'tax_query' => array( | |
array( | |
'taxonomy' => 'advertiser-level', |
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
# ***************************************************************************** | |
# UPDATED VERSION AVAILABLE HERE: | |
# https://github.com/LeCoupa/awesome-cheatsheets/blob/master/tools/nanobox_cli.sh | |
# ***************************************************************************** | |
# ***************************************************************************** | |
# LOCAL ENVIRONMENT | |
# ***************************************************************************** |
OlderNewer