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 | |
function login_with_email_address($username) { | |
$user = get_user_by_email($username); | |
if(!empty($user->user_login)) | |
$username = $user->user_login; | |
return $username; | |
} | |
add_action('wp_authenticate','login_with_email_address'); |
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 | |
//* Do NOT include the opening php tag | |
//* Customize the entry meta in the entry header (requires HTML5 theme support) | |
add_filter( 'genesis_post_info', 'post_info_filter' ); | |
function post_info_filter($post_info) { | |
$post_info = '[post_date] by [post_author_posts_link] [post_comments] [post_edit]'; | |
return $post_info; | |
} |
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 | |
//* Do NOT include the opening php tag | |
//* White Label Soliloquy Plugin | |
add_filter( 'tgmsp_strings', 'tgm_custom_slider_strings' ); | |
function tgm_custom_slider_strings( $strings ) { | |
$strings['add_slider'] = 'Add Slider'; | |
$strings['addon_intro'] = 'The following Addons can be used to extend the functionality of your slider.'; | |
$strings['addons_page_title'] = 'Slider Addons'; |
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 | |
//* Do NOT include the opening php tag | |
//* Add wrapper div to Soliloquy caption | |
add_filter( 'tgmsp_caption_output', 'tgm_custom_caption', 10, 3 ); | |
function tgm_custom_caption( $output, $id, $image ) { | |
return '<div class="soliloquy-caption-wrapper"><div class="soliloquy-caption"><div class="soliloquy-caption-inside">' . do_shortcode( $image['caption'] ) . '</div></div></div>'; | |
} |
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 | |
//* Do NOT include the opening php tag | |
/** Load scripts on Portfolio page */ | |
add_action('genesis_after_footer', 'child_load_portfolio'); | |
function child_load_portfolio() { | |
if(is_page('Portfolio')) { | |
wp_register_script( 'isotope', get_bloginfo('stylesheet_directory').'/lib/js/jquery.isotope.min.js' ); | |
wp_enqueue_script ( 'isotope' ); | |
} |
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
.logo { | |
background: url(images/example.jpg); | |
} | |
@media (-webkit-min-device-pixel-ratio: 2), | |
(min-resolution: 192dpi) { | |
.logo { | |
background: url(images/[email protected]); | |
background-size: 100px 100px; | |
} |
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 | |
//* Do NOT include the opening php tag | |
//* Determin if a page is an ancestor | |
function is_tree($pid) // $pid = The ID of the page we're looking for pages underneath | |
{ | |
global $post; // load details about this page | |
$ancestors = get_post_ancestors($post->$pid); | |
$root = count($ancestors) - 1; |
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 the Child Theme Settings page. | |
* genesis/lib/admin/seo-settings.php | |
*/ | |
/** | |
* Registers a new admin page, providing content and corresponding menu item | |
* for the Child Theme Settings page. | |
*/ |
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 | |
//* Do NOT include the opening php tag | |
//* Customize search form input box text | |
add_filter( 'genesis_search_text', 'sp_search_text' ); | |
function sp_search_text( $text ) { | |
return esc_attr( 'Search my blog...' ); | |
} |
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 | |
//* Do NOT include the opening php tag | |
//* Remove the default Genesis doctype, add new html5 doctype with IE8 detection | |
function mb_html5_doctype() { | |
?> | |
<!DOCTYPE html> | |
<!--[if IE 8]> <html class="lt-ie9" <?php language_attributes( 'html' ); ?>> <![endif]--> | |
<!--[if gt IE 8]><!--> <html <?php language_attributes( 'html' ); ?>> <!--<![endif]--> |
OlderNewer