Skip to content

Instantly share code, notes, and snippets.

View gera3d's full-sized avatar

Gera Yeremin gera3d

View GitHub Profile
@colegeissinger
colegeissinger / functions.php
Created September 5, 2015 00:05
Revert jQuery back a version so ACF works in WordPress 4.3
function cg_revert_jquery_version_admin() {
wp_deregister_script( 'jquery' );
wp_register_script( 'jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js');
wp_enqueue_script( 'jquery' );
}
add_action( 'admin_enqueue_scripts', 'cg_revert_jquery_version_admin' );
@hissy
hissy / really-simple-csv-importer-addon.php
Created February 25, 2015 14:01
[Really Simple CSV Importer] Example: import image from url to custom field
<?php
/*
Plugin Name: Get Remote Image to Custom Field
*/
add_filter('really_simple_csv_importer_post_saved', function($post)
{
if (is_object($post)) {
// Get the meta data of which key is "image"
$image = $post->image;
@westdavidr
westdavidr / yl-api-reference.md
Last active May 7, 2022 15:41
Young Living API reference
@srikat
srikat / functions.php
Last active March 20, 2017 15:08
How to add Beautiful Pro’s mobile responsive menu in other Genesis themes. http://sridharkatakam.com/add-beautiful-pros-mobile-responsive-menu-genesis-themes/
// Enqueue scripts and styles
add_action( 'wp_enqueue_scripts', 'custom_scripts_styles_mobile_responsive' );
function custom_scripts_styles_mobile_responsive() {
wp_enqueue_script( 'beautiful-responsive-menu', get_stylesheet_directory_uri() . '/js/responsive-menu.js', array( 'jquery' ), '1.0.0' );
wp_enqueue_style( 'dashicons' );
}
@jdevalk
jdevalk / archive-speaking_event.php
Last active December 12, 2021 20:13
Genesis helper code for schema
<?php
add_filter( 'genesis_attr_content', 'yoast_schema_empty', 20 );
add_filter( 'genesis_attr_entry', 'yoast_schema_event', 20 );
add_filter( 'genesis_attr_entry-title', 'yoast_itemprop_name', 20 );
add_filter( 'genesis_attr_entry-content', 'yoast_itemprop_description', 20 );
add_filter( 'genesis_post_title_output', 'yoast_title_link_schema', 20 );
/**
* We'll use the post info output to add more meta data about the event.
@jsoverson
jsoverson / device.css
Created February 15, 2013 20:06
Quick css hacks to target android/ios
.visible-android {
display:none;
}
.visible-ios {
display:none;
}
.on-device .visible-android, .on-device .visible-android {
display:inherit;
}
.device-ios .visible-android {