This file contains hidden or 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 a google analytics exclusion cookie to the blog when logged in as admin (or other role) */ --> | |
<!-- /* edit the <body> tag in header.php */ --> | |
<body <?php body_class(); ?>> | |
<!-- /* replace with this line: */ --> | |
<body <?php if (current_user_can('manage_options')) {echo 'onLoad="javascript:pageTracker._setVar(\'test_value\');" ';} body_class(); ?>> | |
<!-- /* | |
to change the role to which this cookie is served, change the capability in (current_user_can('capability')) to one of these: |
This file contains hidden or 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 excerpt functionality to pages. From: http://wordpress.mfields.org/2010/excerpts-for-pages-in-wordpress-3-0/ */ --> | |
<?php add_post_type_support( 'page', 'excerpt' ); ?> | |
<!-- /* To activate, click on the ‘screen options’ tab near the top right when editing a page. There is a checkbox for Excerpts. */ --> | |
This file contains hidden or 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
<!-- /* http://wordpress.stackexchange.com/questions/21707/ */ --> | |
<?php | |
$tags = get_the_tags(); | |
$tag_links = array(); | |
foreach((array)$tags as $tag) | |
$tag_links[] = str_replace(' ', '', $tag->name); |
This file contains hidden or 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
<!-- /* Twitter button: post title and post tags. Prepend tags with hash symbol and remove whitespace within tags. */ --> | |
<a href="http://twitter.com/share" | |
class="twitter-share-button" | |
data-url="<?php bloginfo('url'); ?>/<?php the_ID(); ?>" | |
data-text="<?php the_title(); | |
// remove whitespace inside tags and prepend with # | |
$tags = get_the_tags(); | |
$tags_hashed = array(); | |
foreach((array)$tags as $tag) |
This file contains hidden or 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
<!-- /* customized and valid twitter share button using asynchronous document.write */ --> | |
<!-- /* inspired from http://techoctave.com/c7/posts/40 and gist:1059744 and gist:1059498 */ --> | |
<script type="text/javascript"> | |
//<![CDATA[ | |
(function() { | |
document.write('<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-via="twitter_username" ' | |
+'data-text=\'Article#<?php the_ID(); echo": "; the_title(); $tags = get_the_tags(); $tags_hashed = array(); foreach((array)$tags as $tag) $tags_hashed[] = str_replace(" ", "", $tag->name); echo " #".implode(" #", $tags_hashed); ?>\' ' | |
+'data-url="<?php bloginfo('url'); ?>/<?php the_ID(); ?>" data-lang="en">Tweet this</a> '); | |
var s = document.createElement('SCRIPT'), s1 = document.getElementsByTagName('SCRIPT')[0]; |
This file contains hidden or 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
/* hide sidebar on the right */ | |
.diLZtc .Bu + .Bu + .Bu {display: none !important;} |
This file contains hidden or 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
/* make labels larger in gmail when using "Preview (Dense)" theme */ | |
/* main view */ | |
.ar {font-size: 11px !important;} | |
/* single view */ | |
.ha .cf .hM {font-size: 11px !important;} |
This file contains hidden or 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
/* reduce height of logo section in gmail when using "Preview (Dense)" theme */ | |
div.nH.GcwpPb-Z8OBDd > div.nH {height: 40px;} | |
div.nH.GcwpPb-Z8OBDd > div.nH > div.no {height: 40px !important; margin-top: -25px;} |
This file contains hidden or 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
/* hide instant preview */ | |
/* | |
apply to these domains: | |
encrypted.google.com | |
google.ca | |
www.google.ca | |
google.com | |
www.google.com | |
*/ |
This file contains hidden or 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
/* when logged in, expand latest tweet instead of truncated version */ | |
div.latest-tweet .tweet-content, | |
div.latest-tweet .tweet-row, | |
div.truncated-tweet .tweet-row {height: 60px !important;} | |
div.latest-tweet .tweet-row, div.truncated-tweet .tweet-row {white-space: normal !important;} |