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 | |
/** | |
* acf_group_fields | |
* | |
* This function return an array of all the field names within a field group. | |
* | |
* @type function | |
* @date 24/9/14 | |
* @since 5.0.8 | |
* |
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
(function($) { | |
function fadeloop(){ // loops through elements and fades them sequentially | |
$('.my-element').each(function( index, element){ | |
$(element).delay(index*4000).fadeIn(500).delay(3000).fadeOut(500); | |
}); | |
} | |
function fade(){ // calls itself to repeat | |
window.setTimeout(fadeloop, 0); | |
window.setTimeout(fade, 16000); | |
} |
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
// LINE 3927 of input.js | |
///////////////////////////// | |
// OLD CODE | |
//////////////////////////// | |
// update inputs | |
this.$el.find('.input-lat').val( lat ); | |
this.$el.find('.input-lng').val( lng ).trigger('change'); |
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( | |
// Get children of current page | |
'post_parent' => $post->ID, | |
'post_type' => 'page', | |
); | |
$query = new WP_Query($args); |
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' => 'morning_show' | |
); | |
$actors = new WP_Query($args); | |
if ( $actors->have_posts() ) : while ( $actors->have_posts() ) : $actors->the_post() : | |
the_field('actors'); |
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 | |
'location' => array( | |
array( | |
array( | |
'param' => 'widget', | |
'op' => '==', | |
'value' => 'pages' | |
), | |
array( | |
'param' => 'widget', |
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
$installed_plugins = array(); | |
// check if ACF is installed | |
if ( is_multisite() ) : | |
$network_plugins = get_site_option( 'active_sitewide_plugins', array() ); | |
$site_plugins = get_option( 'active_plugins', array() ); | |
$installed_plugins = array_merge($network_plugins, $site_plugins); | |
else : |
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
// All of your classes in /acf/forms/ are called anonymously | |
// so it's near impossible to filter them out without this jargon. :( | |
// example of won't work, but should | |
remove_filter('in_widget_form', array('acf_form_widget', 'edit_widget'), 10 ); | |
// See http://wordpress.stackexchange.com/questions/137688/remove-actions-filters-added-via-anonymous-functions | |
function acfw_remove_object_filter( $tag, $class, $method = NULL, $priority = NULL ) { | |
$filters = $GLOBALS['wp_filter'][ $tag ]; | |
if ( empty ( $filters ) ) { |
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
// Line 109 from EDD_SL_Changelog_Widget.php | |
$changelog = apply_filters( 'edd_sl_changeloge_widget_output' , get_post_meta( $post_id, '_edd_sl_changelog', true ) ); |
OlderNewer