Helpful links:
This file contains hidden or 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 | |
add_filter( 'pre_set_site_transient_update_core', 'jf_force_autoupdate_response', 10, 1 ); | |
function jf_force_autoupdate_response( $value ) { | |
if ( isset( $value->updates[0]->response ) && 'upgrade' === $value->updates[0]->response ) { | |
$value->updates[0]->response = 'autoupdate'; | |
} | |
return $value; | |
} |
This file contains hidden or 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
Adding group `postfix' (GID 115) ... | |
Done. | |
Adding system user `postfix' (UID 109) ... | |
Adding new user `postfix' (UID 109) with group `postfix' ... | |
Not creating home directory `/var/spool/postfix'. | |
Creating /etc/postfix/dynamicmaps.cf | |
Adding tcp map entry to /etc/postfix/dynamicmaps.cf | |
Adding sqlite map entry to /etc/postfix/dynamicmaps.cf | |
Adding group `postdrop' (GID 116) ... | |
Done. |
This file contains hidden or 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
INFO global: Vagrant version: 1.4.0 | |
INFO global: Ruby version: 2.0.0 | |
INFO global: RubyGems version: 2.0.14 | |
DEBUG global: Loading core plugin: /Applications/Vagrant/embedded/gems/gems/vagrant-1.4.0/plugins/commands/box/plugin.rb | |
INFO manager: Registered plugin: box command | |
DEBUG global: Loading core plugin: /Applications/Vagrant/embedded/gems/gems/vagrant-1.4.0/plugins/commands/destroy/plugin.rb | |
INFO manager: Registered plugin: destroy command | |
DEBUG global: Loading core plugin: /Applications/Vagrant/embedded/gems/gems/vagrant-1.4.0/plugins/commands/halt/plugin.rb | |
INFO manager: Registered plugin: halt command | |
DEBUG global: Loading core plugin: /Applications/Vagrant/embedded/gems/gems/vagrant-1.4.0/plugins/commands/help/plugin.rb |
This file contains hidden or 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
INFO global: Vagrant version: 1.4.0 | |
INFO global: Ruby version: 2.0.0 | |
INFO global: RubyGems version: 2.0.14 | |
INFO manager: Registered plugin: box command | |
INFO manager: Registered plugin: destroy command | |
INFO manager: Registered plugin: halt command | |
INFO manager: Registered plugin: help command | |
INFO manager: Registered plugin: init command | |
INFO manager: Registered plugin: package command | |
INFO manager: Registered plugin: plugin command |
This file contains hidden or 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 | |
$new_global_ver = 'test'; | |
include( locate_template( 'header.php' ) ); // $new_global_var available to header.php | |
////////// OR /////////// | |
get_header( 'test' ); // If one variation is needed, use a different template | |
////////// OR //////////// |
This file contains hidden or 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 | |
$prefix = $blog_prefix = ''; | |
if ( ! got_url_rewrite() ) | |
$prefix = '/index.php'; | |
if ( is_multisite() && !is_subdomain_install() && is_main_site() ) | |
$blog_prefix = '/blog'; | |
if ( isset($_POST['permalink_structure']) || isset($_POST['category_base']) ) { | |
check_admin_referer('update-permalink'); |
This file contains hidden or 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 | |
// from site-new.php | |
$user_id = email_exists( $email ); | |
if ( ! $user_id ) { // Create a new user with a random password | |
$password = wp_generate_password( 12, false ); | |
$user_id = wpmu_create_user( $domain, $password, $email ); | |
if ( false == $user_id ) | |
wp_die( __( 'There was an error creating the user.' ) ); | |
else |
This file contains hidden or 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 | |
// $class_names = join( ' ', apply_filters( 'nav_menu_css_class', array_filter( $classes ), $item, $args ) ); | |
add_filter( 'nav_menu_css_class', 'wsuspine_fix_nav_item_classes', 10, 3 ); | |
function wsuspine_fix_nav_item_classes( $classes, $item, $args ) { | |
if ( in_array( 'current-menu-item', $classes ) ) | |
return array( 'current' ); |
This file contains hidden or 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: Hide Inactive Jetpack Modules | |
Plugin URI: https://gist.github.com/jeremyfelt/7062883 | |
Description: Hides Jetpack modules that are marked as inactive, providing for a shorter list. | |
Version: 0.1 | |
Author: Jeremy Felt | |
Author URI: http://jeremyfelt.com | |
License: GPL2 | |
*/ |