View gist:4332961
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 if ( is_front_page() ) : ?><img src="<?php echo get_stylesheet_directory_uri(); ?>/images/specific image for cat"> | |
<?php elseif ( is_category( 'category 1' ) || has_category ('category 1')) : ?> | |
<img src="<?php echo get_stylesheet_directory_uri(); ?>/images/specific image for cat"> | |
<?php elseif ( is_category( 'category 2' ) || has_category ('category 2')) : ?> | |
<img src="<?php echo get_stylesheet_directory_uri(); ?>/images/specific image for cat"> | |
<?php elseif ( is_category( 'category 3' ) || has_category ('category 3')) : ?> | |
<img src="<?php echo get_stylesheet_directory_uri(); ?>/images/specific image for cat"> | |
<?php elseif ( is_category( 'other' ) ) : ?> | |
<img src="<?php echo get_stylesheet_directory_uri(); ?>/images/specific image for cat"> | |
<?php else: ?> |
View gist:4504569
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
<iframe style="border: 0px none transparent;" src="http://www.ustream.tv/embed/your specific id#" frameborder="0" scrolling="no" width="525" height="333"></iframe><a style="padding: 2px 0px 4px; width: 525px; background: #ffffff; display: block; color: #000000; font-weight: normal; font-size: 10px; text-decoration: underline; text-align: center;" href="Destination Link" target="_blank">Link Anchor Text</a> | |
/*Adding the social stream -- specify width that's specific to your site*/ | |
<iframe width="330" scrolling="no" height="625" frameborder="0" style="border: 0px none transparent;" src="http://www.ustream.tv/socialstream/your specific id#"> | |
View GenesisPostMeta
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
/** Customize the post meta function */ | |
add_filter( 'genesis_post_meta', 'post_meta_filter' ); | |
function post_meta_filter($post_meta) { | |
if ( !is_page() ) { | |
$post_meta = '[post_categories before="CUSTOM CATEGORY NAME"] [post_tags before="CUSTOM TAG NAME"]'; | |
return $post_meta; |
View gist:6072596
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
/* Change default comment Speak Your Mind */ | |
function change_default_comment_text($args) { | |
$args['title_reply'] = 'Leave a Comment'; | |
return $args; | |
} | |
add_filter( 'genesis_comment_form_args', 'change_default_comment_text' ); |
View gist:6313917
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
Add to the page or it will detect any ph# on page and make it clickable for iPhone. | |
<meta name="format-detection" content="telephone=no"> | |
Then wrap specified phone number: | |
<a href="tel:1-800-555-5555">Anchor to any words or combo of numbers and/or letters</a> |
View gist:7895603
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
/*Add This Code To Site's Head*/ | |
<scripttype="text/javascript"]]> var _gaq = _gaq ||[]; _gaq.push(['_setAccount','UA-XXXXX-X']); _gaq.push(['_trackPageview']); (function(){ var ga = document.createElement('script'); ga.type ='text/javascript'; ga.async =true; ga.src =('https:'== document.location.protocol ?'https://ssl':'http://www')+'.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })();</script> | |
Replace UA-XXXXX-X with site's Google Analytics Code | |
Go To Google Analytics > Conversions > Goal URLS > Create Event | |
Select Custom | |
Set Goal Detail's Category, Action & Label |
View gist:5960970
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
add_action( 'genesis_loop', 'minimum_grid_loop_helper' ); | |
function minimum_grid_loop_helper() { | |
if ( function_exists( 'genesis_grid_loop' ) ) { | |
genesis_grid_loop( array( | |
'features' => 0, | |
'feature_image_size' => 'featured', | |
'feature_image_class' => 'post-image', | |
'feature_content_limit' => 0, | |
'grid_image_size' => 0, |
View Removing Blog Post From Home Page in Genesis
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
/** Removing Blog Post From Home Page */ | |
remove_action( 'genesis_loop', 'genesis_do_loop' );add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); | |
genesis(); | |
View functions.php
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 everything except for this opening line to your functions file | |
add_filter( 'wp_nav_menu_items', 'sp_add_loginout_link', 10, 2 ); | |
function sp_add_loginout_link( $items, $args ) { | |
// Change 'primary' to 'secondary' to put the login link in your secondary nav bar | |
if ( $args->theme_location != 'primary' ) | |
return $items; | |
if ( is_user_logged_in() ) { | |
$items .= '<li class="menu-item"><a href="'. wp_logout_url() .'">Log Out</a></li>'; | |
} else { | |
$items .= '<li class="menu-item"><a href="'. site_url('wp-login.php') .'">Log In</a></li>'; |
OlderNewer