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 fb_xfbml_js() { | |
?> | |
<div id="fb-root"></div> | |
<script> | |
(function(d, s, id) { | |
var js, fjs = d.getElementsByTagName(s)[0]; | |
if (d.getElementById(id)) return; | |
js = d.createElement(s); js.id = id; |
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 custom_body_classes($classes) { | |
if (is_category('Videos')) | |
$classes[] = "videos"; | |
return $classes; | |
} | |
add_filter('thesis_body_classes','custom_body_classes'); | |
function no_sidebars() { | |
if (is_category('Videos')) | |
return false; |
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 remove_headline() { | |
return (is_single()) ? false : true; | |
} | |
add_filter('thesis_show_headline_area', 'remove_headline'); | |
function large_headline() { | |
global $wp_query; | |
$post_ID = $wp_query->post->ID; | |
if (is_single()) { | |
?> |
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
# strip '.html' off any requests except in the dashboard | |
RewriteBase / | |
RewriteCond %{REQUEST_URI} !^/?(wp-admin|wp-includes)/(.*)$ | |
RewriteRule ^(.*)\.html$ http://example.com/$1 [R=301,L] |
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
tell application "Address Book" | |
set num to 0 | |
repeat with i from 1 to (count every person) | |
if (note of person i) is not equal to "" then | |
set note of person i to "" | |
set num to num + 1 | |
end if | |
end repeat | |
display dialog "Removed " & num & " notes." buttons {"OK"} | |
save |
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
tell application "Address Book" | |
set output to "" | |
repeat with this_person in every person | |
set numurl to count (urls of this_person) | |
if numurl > 0 then | |
set theurls to properties of urls of this_person | |
repeat with this_url in theurls | |
-- Capturing the urls and a new line | |
set output to output & (value of this_url as string) & return | |
if value of this_url contains "google.com" then |
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('manage_location_posts_columns' , 'add_post_columns'); | |
add_action( 'manage_location_posts_custom_column' , 'state_column', 10, 2 ); | |
function add_post_columns($columns) { | |
$columns['state'] = 'State/Territory'; | |
return $columns; | |
} |
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 auto_featured_image() { | |
global $post; | |
if (!has_post_thumbnail($post->ID)) { | |
$attached_image = get_children( "post_parent=$post->ID&post_type=attachment&post_mime_type=image&numberposts=1" ); | |
if ($attached_image) { | |
foreach ($attached_image as $attachment_id => $attachment) { | |
set_post_thumbnail($post->ID, $attachment_id); | |
} |
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 | |
$header = array( | |
'default-image' => get_stylesheet_directory_uri().'/images/pageone.png', | |
'random-default' => false, | |
'width' => 320, | |
'height' => 60, | |
'flex-height' => true, | |
'flex-width' => true, | |
'default-text-color' => '#333333', |
OlderNewer