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
function mv_browser_body_class($classes) { | |
global $is_lynx, $is_gecko, $is_IE, $is_opera, $is_NS4, $is_safari, $is_chrome, $is_iphone; | |
if($is_lynx) $classes[] = 'lynx'; | |
elseif($is_gecko) $classes[] = 'gecko'; | |
elseif($is_opera) $classes[] = 'opera'; | |
elseif($is_NS4) $classes[] = 'ns4'; | |
elseif($is_safari) $classes[] = 'safari'; | |
elseif($is_chrome) $classes[] = 'chrome'; | |
elseif($is_IE) { | |
$classes[] = 'ie'; |
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
// Original CSS: | |
.content .pager li { | |
display: inline-block; | |
} | |
// Fixed CSS: | |
.content .pager li { | |
display: inline-block; |
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
function SearchFilter($query) { | |
if ($query->is_search) { | |
$query->set('post_type', 'post'); | |
} | |
return $query; | |
} | |
add_filter('pre_get_posts','SearchFilter'); |
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
<?php $my_query = new WP_Query('page_id=ID-FOR-PAGE'); | |
while ($my_query->have_posts()) : $my_query->the_post(); | |
$do_not_duplicate = $post->ID; | |
?> | |
<?php the_content(); ?> | |
<?php endwhile; ?> |
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
<?php $do_not_duplicate = array(); | |
$my_query = new WP_Query( | |
array( | |
'posts_per_page' => 3, | |
'post__in' => get_option( 'sticky_posts' ), | |
'ignore_sticky_posts' => true | |
) | |
); | |
while ($my_query->have_posts()) : $my_query->the_post(); |
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
$('a.goback').click(function() { | |
window.history.back(); | |
return false; | |
}); |
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
// Remove "Quick Edit" from Custom Post Types | |
function remove_quick_edit( $actions ) { | |
global $post; | |
if( $post->post_type == 'Custom_Post_Name_Here' ) { | |
unset($actions['inline hide-if-no-js']); | |
} | |
return $actions; | |
} | |
if (is_admin()) { |
NewerOlder