/**
* Returns ads which are marked as featured for slider
*/
function cp_get_featured_slider_ads() {
$args = array(
'post_type' => APP_POST_TYPE,
'post_status' => 'publish',
'post__in' => get_option('sticky_posts'),
'posts_per_page' => 15,
'orderby' => 'rand',
'suppress_filters' => false,
);
$args = apply_filters( 'cp_featured_slider_args', $args );
$featured = new WP_Query( $args );
if ( ! $featured->have_posts() )
return false;
return $featured;
}
if ( ! $featured->have_posts() && ! wp_get_attachment_image($image_id, 'featured-thumbnail') )
There are currently 1 users browsing this thread. (0 members and 1 guests)