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
::-webkit-input-placeholder { /* WebKit, Blink, Edge */ | |
color:#909 !important; | |
} | |
:-moz-placeholder { /* Mozilla Firefox 4 to 18 */ | |
color:#909 !important; | |
opacity:1 !important; | |
} | |
::-moz-placeholder { /* Mozilla Firefox 19+ */ | |
color:#909 !important; | |
opacity:1 !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
//seach template for coach cpt | |
function template_chooser($template) { | |
global $wp_query; $post_type = get_query_var('post_type'); | |
if( $wp_query->is_search && $post_type == 'coach' ) { | |
return locate_template('page_coach.php'); | |
} return $template; | |
} add_filter('template_include', 'template_chooser'); |
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
//create shortcode for a coach archive row | |
function myt_create_shortcode_coach_post_type(){ | |
$args = array( | |
'post_type' => coach, | |
'posts_per_page' => 6, | |
'post_status' => publish | |
); | |
$query = new WP_Query($args); |
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 my_pmprorh_init() { | |
// Don't break if Register Helper is not loaded. | |
if ( ! function_exists( 'pmprorh_add_registration_field' ) ) { | |
return false; | |
} | |
// Define the fields. | |
$fields = array(); | |
$fields[] = new PMProRH_Field( | |
'first_name', // input name, will also be used as meta key |
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($) { | |
// store the image link inside a variable from 'src' attribute | |
var getImageSrc = $('.banner-front-left .fl-post-grid-image img').attr('src'); | |
// add div background image using the variable above | |
$('.banner-front-left .fl-post-grid-image').css('background-image', 'url(' + getImageSrc + ')'); | |
// store the image link inside a variable from 'src' attribute | |
var getImageSrc = $('.banner-top-right .fl-post-grid-image img').attr('src'); |
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
<div class="r-author"><?php the_author_meta( 'user_firstname', $userID ); ?> <?php the_author_meta( 'user_lastname', $userID ); ?> - <?php the_date(); ?> </div> |
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_action("load-post-new.php", 'block_post'); | |
function block_post() | |
{ | |
if($_GET["post_type"] == "physician" || "posts" ) | |
wp_redirect("edit.php?post_type=physician"); | |
} |
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 && !is_admin() ) { | |
$query->set('post_type',array('post','page')); | |
} | |
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 | |
global $wp_query; | |
$total_results = $wp_query->found_posts; | |
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1; | |
?> | |
Found <?php echo $total_results ;?> Results | |
Page <?php echo $paged; ?> of <?php echo $wp_query->max_num_pages; ?><br /> |
NewerOlder