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 | |
remove_action( 'genesis_loop', 'genesis_do_loop' ); | |
add_action( 'genesis_loop', 'focus_grid_loop_helper' ); | |
/** Add support for Genesis Grid Loop */ | |
function focus_grid_loop_helper() { | |
if ( function_exists( 'genesis_grid_loop' ) ) { | |
genesis_grid_loop( array( | |
'features' => 4, |
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 | |
// Filter is applied to all forms | |
//add_filter('gform_pre_render', 'wps_populate_person'); | |
// Filter only applied to Form id = 3 | |
add_filter('gform_pre_render_3', 'wps_populate_person'); | |
/** | |
* Pre-populates radios based on previous name field | |
* Searches post type 'person' |
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 | |
/** | |
* Taxonomies | |
* | |
* This file registers any custom taxonomies | |
* | |
* @package WPS_Starter_Genesis_Child | |
* @author Travis Smith <travis@wpsmith.net> | |
* @copyright Copyright (c) 2012, Travis Smith | |
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License |
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 | |
/** | |
* Creates HTML markup for taxonomy dropdown | |
* | |
* @param string $taxonomy Registered taxonomy name | |
*/ | |
function we_tax_dropdown( $taxonomy ) { | |
$terms = get_terms( $taxonomy ); | |
$taxonomy = get_taxonomy( $taxonomy ); | |
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
jQuery(document).ready(function($){ | |
// Mobile navigation | |
$('#prim-selector, #sec-selector').change(function(){ | |
if ($(this).val()!='') { | |
window.location.href=$(this).val(); | |
} | |
}); | |
}); |
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
Array | |
( | |
[width] => 612 | |
[height] => 792 | |
[hwstring_small] => height='96' width='74' | |
[file] => 2012/lowercase-print-dn-letter-a-z.jpg | |
[sizes] => Array | |
( | |
[thumbnail] => Array | |
( |
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_status' => 'inherit', // Default status of attachments | |
'post_type' => array( 'attachment' ), | |
'meta_key' => '_wp_attachment_metadata', | |
'meta_value' => 'FinePix J10', | |
'meta_compare' => 'LIKE', | |
); | |
$attachment_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 | |
add_filter( 'genesis_comment_form_args', 'wps_comment_form_args' ); | |
/** | |
* Remove website field from Comments Form | |
* | |
* @param array $args Comments form arguments. | |
* @return array $args Modified Comments form arguments. | |
*/ | |
function wps_comment_form_args( $args ) { | |
unset( $args['fields']['url'] ); |