function widget($args, $instance) { extract($args); /* Our variables from the widget settings. */ $page_id = (int) $instance['page_id']; if (empty($page_id) || $page_id < 1) { return false; } $page_data = get_page($page_id); $title = apply_filters('widget_title', trim($page_data->post_title), $instance, $this->id_base); $link_title = (bool) $instance['link_title']; if (!empty($page_data->post_content)) { echo $before_widget; get_the_image(array('post_id' => $page_data->ID, 'size' => 'featured-cat', 'width' => 310, 'height' => 220, 'before' => '<div class="post-thumb">', 'after' => '</div>')); if ($title) { echo $before_title; if ($link_title) { echo '<a href="' . esc_url(get_permalink($page_data->ID)) . '">'; } echo $title; if ($link_title) { echo '</a>'; } echo $after_title; } echo apply_filters('the_excerpt', trim($page_data->post_excerpt)); echo $after_widget; } }
function widget($args, $instance) { extract($args); /* User-selected settings. */ $title = apply_filters('widget_title', $instance['title']); $category = $instance['category']; $show_count = $instance['show_count']; $show_date = $instance['show_date'] ? true : false; $show_thumb = $instance['show_thumb'] ? true : false; $show_excerpt = $instance['show_excerpt'] ? true : false; $excerpt_length = $instance['excerpt_length']; $show_title = $instance['hide_title'] ? false : true; /* Before widget (defined by themes). */ echo $before_widget; /* Title of widget (before and after defined by themes). */ if ($title) { echo $before_title . $title . $after_title; } echo '<ul class="wpzoom-feature-posts">'; $query_opts = apply_filters('wpzoom_query', array('posts_per_page' => $show_count, 'post_type' => 'post')); if ($category) { $query_opts['cat'] = $category; } query_posts($query_opts); if (have_posts()) { while (have_posts()) { the_post(); echo '<li>'; if ($show_thumb) { $custom_field = option::get('cf_use') == 'on' ? get_post_meta($post->ID, option::get('cf_photo'), true) : ''; $args = array('size' => 'recent-widget', 'width' => $instance['thumb_width'], 'height' => $instance['thumb_height']); if ($custom_field) { $args['meta_key'] = option::get('cf_photo'); } get_the_image($args); } if ($show_title) { echo '<a href="' . get_permalink() . '">' . get_the_title() . '</a>'; } if ($show_date) { echo '<small>' . get_the_date() . '</small>'; } if ($show_excerpt) { $the_excerpt = get_the_excerpt(); // cut to character limit $the_excerpt = substr($the_excerpt, 0, $excerpt_length); // cut to last space $the_excerpt = substr($the_excerpt, 0, strrpos($the_excerpt, ' ')); echo '<span class="post-excerpt">' . $the_excerpt . '</span>'; } echo '<div class="clear"></div></li>'; } } else { } //Reset query_posts wp_reset_query(); echo '</ul><div class="clear"></div>'; /* After widget (defined by themes). */ echo $after_widget; }
/** * Facebook Opengraph - Adds Facebook open graph meta fields to the theme header. * * This program is free software; you can redistribute it and/or modify it under the terms of the GNU * General Public License version 2, as published by the Free Software Foundation. You may NOT assume * that you can use any other version of the GPL. * * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * * @package FacebookMetaFields * @version 0.0.1 * @author Jason Conroy <*****@*****.**> * @copyright Copyright (c) 2008 - 2011, Jason Conroy * @link http://findingsimple.com * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html */ function facebook_meta() { $image = get_the_image(array('format' => 'array')); if (!empty($image)) { $image = $image['url']; } else { $image = ""; } ?> <!-- Facebook Meta --> <?php if (is_single()) { ?> <meta property="og:title" content="<?php the_title(); ?> "/> <meta property="og:type" content="article" /> <meta property="og:url" content="<?php the_permalink(); ?> "/> <meta property="og:image" content="<?php echo $image; ?> "/> <meta property="og:description" content="<?php echo fb_description(); ?> " /> <?php } else { ?> <meta property="og:site_name" content="<?php bloginfo('name'); ?> " /> <meta property="og:description" content="<?php echo fb_description(); ?> " /> <meta property="og:type" content="website" /> <meta property="og:image" content="<?php echo $image; ?> " /> <?php } ?> <!-- END Facebook Meta --> <?php }
/** * Generates the relevant template info for facebook opengraph * filter hook. * * @since 1.3.0 * @access public * @return void */ function bon_meta_opengraph() { if (is_singular()) { global $post; $img = get_the_image(array('post_id' => $post->ID, 'attachment' => true, 'image_scan' => true, 'size' => 'full', 'format' => 'array', 'echo' => false)); $content = wp_trim_words($post->post_content, $num_words = 50, $more = null); $title = $post->post_title; echo '<meta property="og:title" content="' . apply_filters('bon_og_meta_title', $title) . '" />' . " \n"; echo '<meta property="og:description" content="' . apply_filters('bon_og_meta_desc', strip_tags(strip_shortcodes($content))) . '" />' . " \n"; echo '<meta property="og:url" content="' . get_the_permalink() . '" />' . " \n"; if ($img && isset($img['src'])) { echo '<meta property="og:image" content="' . apply_filters('bon_og_meta_image', $img['src']) . '" />' . " \n"; } echo '<meta property="og:type" content="article" />' . " \n"; } }
/** * Outputs the widget based on the arguments input through the widget controls. * * @since 0.1.0 */ function widget($sidebar, $instance) { extract($sidebar); /* Output the theme's $before_widget wrapper. */ echo $before_widget; /* If a title was input by the user, display it. */ if (!empty($instance['title'])) { echo $before_title . apply_filters('widget_title', $instance['title'], $instance, $this->id_base) . $after_title; } $loop = new WP_Query(array('posts_per_page' => $instance['posts_per_page'], 'tax_query' => array(array('taxonomy' => 'post_format', 'field' => 'slug', 'terms' => array('post-format-gallery'))))); if ($loop->have_posts()) { /* Set up some default variables to use in the gallery. */ $gallery_columns = 3; $gallery_iterator = 0; echo '<div class="gallery">'; while ($loop->have_posts()) { $loop->the_post(); if ($gallery_columns > 0 && $gallery_iterator % $gallery_columns == 0) { echo '<div class="gallery-row gallery-clear">'; } ?> <div class="gallery-item col-<?php echo esc_attr($gallery_columns); ?> "> <div class="gallery-icon"> <?php get_the_image(array('image_scan' => true, 'size' => 'thumbnail', 'meta_key' => false, 'default_image' => trailingslashit(get_template_directory_uri()) . 'images/thumbnail-default.png')); ?> </div> </div> <?php if ($gallery_columns > 0 && ++$gallery_iterator % $gallery_columns == 0) { echo '</div>'; } } if ($gallery_columns > 0 && $gallery_iterator % $gallery_columns !== 0) { echo '</div>'; } echo '</div>'; } wp_reset_query(); echo $after_widget; }
/** * Displays the content of custom portfolio item columns on the edit screen. * * @since 0.1.0 * @access public * @param string $column * @param int $post_id * @return void */ function ccp_manage_portfolio_item_columns($column, $post_id) { global $post; switch ($column) { case 'thumbnail': if (has_post_thumbnail()) { the_post_thumbnail(array(40, 40)); } elseif (function_exists('get_the_image')) { get_the_image(array('image_scan' => true, 'width' => 40, 'height' => 40)); } break; /* Just break out of the switch statement for everything else. */ /* Just break out of the switch statement for everything else. */ default: break; } }
/** * Returns the link to image */ public static function getImage($width, $height, $location = 'c') { global $blog_id; $image = get_the_image(array('format' => 'array')); if (isset($image['src']) && $image['src'] != '') { $image = $image['src']; $imageParts = explode('/files/', $image); $filehost = parse_url($image); $localhost = $_SERVER['HTTP_HOST']; if (isset($imageParts[1]) && $filehost['host'] == $localhost) { $image = '/blogs.dir/' . $blog_id . '/files/' . $imageParts[1]; } $location = ui::getCropLocation($location); return get_template_directory_uri() . '/functions/theme/thumb.php?src=' . $image . '&w=' . $width . '&h=' . $height . '&zc=1' . '&a=' . $location; } return false; }
function webnus_postfromblog($attributes, $content = null) { extract(shortcode_atts(array('post' => ''), $attributes)); ob_start(); $query = new WP_Query('p=' . $post . ''); if ($query->have_posts()) { $query->the_post(); ?> <article class="a-post-box"> <figure class="latest-img"><?php get_the_image(array('meta_key' => array('thumbnail', 'thumbnail'), 'size' => 'latest-cover')); ?> </figure> <div class="latest-overlay"></div> <div class="latest-txt"> <h4 class="latest-title"><a href="<?php the_permalink(); ?> "><?php the_title(); ?> </a></h4> <span class="latest-cat"><?php the_category(' / '); ?> </span> <span class="latest-meta"> <span class="latest-date"><i class="fa-clock-o"></i> <?php the_time('d M y'); ?> </span> </span> </div> </article> <?php } $out = ob_get_contents(); ob_end_clean(); wp_reset_query(); return $out; }
function feed_thumbnails() { if (function_exists('get_the_image') and $thumb = get_the_image('format=array&echo=0')) { $thumb[0] = $thumb['url']; } else { if (function_exists('has_post_thumbnail') and has_post_thumbnail()) { $thumb = wp_get_attachment_image_src(get_post_thumbnail_id(), 'thumbnail'); } else { if (function_exists('get_post_thumbnail_src')) { $thumb = get_post_thumbnail_src(); if (preg_match('|^<img src="([^"]+)"|', $thumb[0], $m)) { $thumb[0] = $m[1]; } } else { $thumb = false; } } } if (!empty($thumb)) { echo "\t" . '<enclosure url="' . $thumb[0] . '" />' . "\n"; } }
the_content(); ?> <?php wp_link_pages(); ?> </div><!-- .entry-content --> </div><!-- .wrap --> <?php } else { // If not viewing a single post. ?> <?php get_the_image(array('size' => 'saga-large', 'min_width' => 1100, 'min_height' => 500, 'order' => array('featured', 'attachment'), 'before' => '<div class="featured-media">', 'after' => '</div>')); ?> <div class="wrap"> <header class="entry-header"> <?php the_title('<h2 ' . hybrid_get_attr('entry-title') . '><a href="' . get_permalink() . '" rel="bookmark" itemprop="url">', '</a></h2>'); ?> </header><!-- .entry-header --> <div <?php hybrid_attr('entry-summary'); ?> > <?php
<div id="post-<?php the_ID(); ?> " class="<?php hybrid_entry_class(); ?> "> <?php do_atomic('open_entry'); // oxygen_open_entry ?> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('meta_key' => 'Thumbnail', 'size' => 'archive-thumbnail', 'image_class' => 'featured', 'width' => 470, 'height' => 140, 'default_image' => get_template_directory_uri() . '/images/archive-thumbnail-placeholder.gif')); } ?> <div class="entry-header"> <?php echo apply_atomic_shortcode('entry_title', '[entry-title]'); ?> <?php echo apply_atomic_shortcode('byline_date', '<div class="byline byline-date">' . __('[entry-published]', 'oxygen') . '</div>'); ?> <?php echo apply_atomic_shortcode('byline_author', '<div class="byline byline-author">' . __('by [entry-author]', 'oxygen') . '</div>');
<?php global $udesign_options, $post; $the_post_thumbnail_link = get_post_meta($post->ID, 'post_thumbnail', true) ? get_post_meta($post->ID, 'post_thumbnail', true) : get_post_meta($post->ID, 'thumbnail', true); $default_thumb = get_bloginfo('template_url') . '/styles/common-images/default-thumb.png'; $shadow_class = $thumb_frame_shadow == '' | $thumb_frame_shadow == false ? '' : ' frame-shadow'; // $thumb_frame_shadow is set in 'latestPost-widget.php' file // the case when "Get The Image" plugin is available (installed and activated) if (function_exists('get_the_image')) { if ($udesign_options['default_thumb_on'] == 'yes') { // Default thumbnail option is selected $the_thumb_html_as_array = get_the_image(array('meta_key' => array('post_thumbnail', 'thumbnail'), 'format' => 'array', 'size' => 'full', 'default_image' => $default_thumb, 'link_to_post' => false, 'image_scan' => true, 'width' => $post_thumb_width, 'height' => $post_thumb_height, 'cache' => false, 'echo' => false)); } else { // Default thumbnail option is NOT selected $the_thumb_html_as_array = get_the_image(array('meta_key' => array('post_thumbnail', 'thumbnail'), 'format' => 'array', 'size' => 'full', 'default_image' => false, 'link_to_post' => false, 'image_scan' => true, 'width' => $post_thumb_width, 'height' => $post_thumb_height, 'cache' => false, 'echo' => false)); } echo $the_thumb_html_as_array[src] ? '<span class="small-custom-frame alignleft' . $shadow_class . '"><a href="' . get_permalink() . '" title="' . __("Permanent Link to", 'udesign') . ' ' . the_title('', '', false) . '"><img src="' . get_bloginfo("template_directory") . '/scripts/timthumb.php?src=' . $the_thumb_html_as_array[url] . '&w=' . $post_thumb_width . '&h=' . $post_thumb_height . '&zc=1&q=100" width="' . $post_thumb_width . '" height="' . $post_thumb_height . '" alt="' . $the_thumb_html_as_array[alt] . '" /></a></span>' : ''; } else { // the case when "Get The Image" plugin is NOT available if ($udesign_options['default_thumb_on'] == 'yes') { // Default thumbnail option is selected if ($the_post_thumbnail_link) { // look for the thumbnail passed as a 'post_thumbnail' or 'thumbnail' custom field ?> <span class="small-custom-frame alignleft<?php echo $shadow_class; ?> "><a href="<?php the_permalink(); ?> " title="<?php
?> " title="<?php the_title(); ?> ">Permalink</a> <a href="http://www.addthis.com/bookmark.php?v=250&pubid=xa-4db9efe25b1310bd" title="Share" class="addthis_button">Share</a> <script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#pubid=xa-4db9efe25b1310bd"></script> </div> </div><!-- .entry-summary --> <div class="feature-container"> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('meta_key' => 'Thumbnail', 'size' => 'full', 'image_class' => 'page-feature', 'link_to_post' => false)); } ?> </div> <?php do_atomic('close_entry'); // dschool_close_entry ?> </div><!-- .hentry --> <?php do_atomic('after_entry'); // dschool_after_entry ?>
<?php comments_popup_link(number_format_i18n(0), number_format_i18n(1), '%', 'comments-link', ''); ?> <?php edit_post_link(); ?> </div><!-- .entry-byline --> </header><!-- .entry-header --> <div <?php hybrid_attr('entry-summary'); ?> > <?php get_the_image(); ?> <?php the_excerpt(); ?> </div><!-- .entry-summary --> <footer class="entry-footer"> <?php hybrid_post_terms(array('taxonomy' => 'category', 'text' => esc_html__('Posted in %s', 'magik'))); ?> <?php hybrid_post_terms(array('taxonomy' => 'post_tag', 'text' => esc_html__('Tagged %s', 'magik'))); ?> </footer><!-- .entry-footer -->
<?php tha_entry_before(); ?> <article <?php hybrid_attr('post'); ?> > <?php tha_entry_top(); ?> <?php // Display a featured image if one has been set. get_the_image(array('size' => 'compass-full', 'before' => '<div class="featured-media image">', 'after' => '</div>')); ?> <header class="entry-header"> <?php the_title('<h2 ' . hybrid_get_attr('entry-title') . '><a href="' . get_permalink() . '" rel="bookmark" itemprop="url">', '</a></h2>'); ?> <p class="entry-meta"> <?php hybrid_post_format_link(); ?> <span <?php hybrid_attr('entry-author'); ?>
/** * Outputs the widget based on the arguments input through the widget controls. * * @since 1.0 */ function widget($sidebar, $instance) { extract($sidebar); /* Set the $args for wp_get_archives() to the $instance array. */ $args = $instance; /* Overwrite the $echo argument and set it to false. */ $args['echo'] = false; /* Output the theme's $before_widget wrapper. */ echo $before_widget; /* If a title was input by the user, display it. */ if (!empty($instance['title'])) { echo $before_title . apply_filters('widget_title', $instance['title'], $instance, $this->id_base) . $after_title; } ?> <div class="row"> <div class="column large-12 featured-listing-carousel"> <?php $prefix = bon_get_prefix(); $query = array('post_type' => 'car-listing', 'posts_per_page' => $args['limit'], 'meta_query' => array(array('key' => $prefix . 'listing_featured', 'value' => true, 'compare' => '='))); $featured_query = new WP_Query($query); if ($featured_query->have_posts()) { $i = 0; ?> <script> jQuery(document).ready(function($){ $('#<?php echo $this->id; ?> -slider').flexslider({ animation: "slide", controlNav: false, controlsContainer: "#<?php echo $this->id; ?> -nav" }); }); </script> <div id="<?php echo $this->id; ?> -nav" class="featured-listing-nav"> </div> <div id="<?php echo $this->id; ?> -slider"> <ul class="slides"> <?php while ($featured_query->have_posts()) { $featured_query->the_post(); ?> <?php if ($i == 0) { ?> <li> <?php } ?> <div class="featured-item featured-car-item"> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('size' => 'listing_medium', 'before' => '<div class="featured-image">', 'after' => '</div>')); } ?> <div class="featured-item-title"> <h2 class="title"><i class="bonicons bi-link"></i><a href="<?php the_permalink(); ?> " title="<?php the_title_attribute(); ?> " ><?php the_title(); ?> </a></h2> </div> </div> <?php $i++; if ($i == $args['per_slide']) { $i = 0; ?> </li> <?php } ?> <?php } ?> <?php if ($i > 0) { ?> </li> <?php } ?> </ul> </div> <?php } else { echo '<p>' . __('No property listing were found', 'bon') . '</p>'; } wp_reset_query(); ?> </div> </div> <?php /* Close the theme's widget wrapper. */ echo $after_widget; }
/** * Adds the post format image to the content if no image is found in the post content. Note, this is not run * by default. To use, add the filter to 'the_content'. * * @since 0.9.0 * @access public * @param string $content * @return string */ function omega_image_content($content) { if (has_post_format('image')) { preg_match('/<img.*?>/', $content, $matches); if (empty($matches) && current_theme_supports('get-the-image')) { $content = get_the_image(array('meta_key' => false, 'size' => 'large', 'link_to_post' => false, 'echo' => false)) . $content; } elseif (empty($matches)) { $content = get_the_post_thumbnail(get_the_ID(), 'large') . $content; } } return $content; }
<footer class="entry-footer"> <?php hybrid_post_terms(array('taxonomy' => 'category', 'text' => __('Posted in %s', 'stargazer'))); ?> <?php hybrid_post_terms(array('taxonomy' => 'post_tag', 'text' => __('Tagged %s', 'stargazer'), 'before' => '<br />')); ?> </footer><!-- .entry-footer --> <?php } else { // If not viewing a single post. ?> <?php get_the_image(array('size' => 'stargazer-full')); ?> <header class="entry-header"> <?php the_title('<h2 ' . hybrid_get_attr('entry-title') . '><a href="' . get_permalink() . '" rel="bookmark" itemprop="url">', '</a></h2>'); ?> <div class="entry-byline"> <?php hybrid_post_format_link(); ?> <span <?php hybrid_attr('entry-author'); ?>
<?php $loop = new WP_Query(array('post_type' => apply_filters('news_video_post_type', 'video'), 'orderby' => 'comment_count', 'posts_per_page' => 3)); ?> <?php while ($loop->have_posts()) { $loop->the_post(); ?> <div class="<?php hybrid_entry_class(); ?> "> <?php get_the_image(array('meta_key' => array('Thumbnail'), 'size' => 'news-thumbnail')); ?> <?php echo apply_atomic_shortcode('entry_title', the_title('<h4 class="entry-title"><a href="' . get_permalink() . '" title="' . the_title_attribute('echo=0') . '" rel="bookmark">', '</a></h4>', false)); ?> <?php echo apply_atomic_shortcode('byline', '<div class="byline">[entry-published]</div>'); ?> </div><!-- .hentry --> <?php } ?>
<?php echo apply_atomic_shortcode('entry_author_avatar', '[entry-author-avatar]'); ?> <?php echo apply_atomic_shortcode('entry_tag', '<div class="entry-tag">' . __('[entry-terms text="' . __('Tagged in:', 'bon') . '"]', 'bon') . '</div>'); ?> </footer><!-- .entry-footer --> <?php } else { ?> <header class="entry-header"> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('attachment' => false, 'size' => 'listing_large', 'before' => '<div class="featured-image">', 'after' => '</div>')); } ?> <?php echo apply_atomic_shortcode('entry_title', the_title('<h3 class="entry-title"><a href="' . get_permalink() . '" title="' . the_title_attribute(array('before' => 'Permalink to: ', 'echo' => false)) . '">', '</a></h3>', false)); ?> <?php echo apply_atomic_shortcode('entry_byline', '<div class="entry-byline">' . __('[entry-icon class="show-for-large"] [entry-author] [entry-published format="M, d Y" text="' . __('Posted on ', 'bon') . '"] [entry-comments-link] [entry-terms text="' . __('Category', 'bon') . ':" limit="1" exclude_child="true" taxonomy="category"] [entry-edit-link]', 'bon') . '</div>'); ?> </header><!-- .entry-header --> <div class="entry-summary"> <?php the_excerpt(); ?> <?php
?> " class="<?php hybrid_entry_class(); ?> "> <?php do_atomic('open_entry'); // oxygen_open_entry ?> <div class="post-content"> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('meta_key' => 'Thumbnail', 'size' => 'single-thumbnail', 'link_to_post' => false, 'image_class' => 'featured', 'attachment' => false, 'width' => 470, 'height' => 260)); } ?> <?php echo apply_atomic_shortcode('entry_title', '[entry-title]'); ?> <?php echo apply_atomic_shortcode('byline', '<div class="byline">' . __('[entry-published] · by [entry-author] · in [entry-terms taxonomy="category" before=""] [entry-edit-link before=" · "]', hybrid_get_parent_textdomain()) . '</div>'); ?> <div class="entry-content"> <?php the_content(__('Continue reading <span class="meta-nav">→</span>', hybrid_get_parent_textdomain()));
hybrid_attr('entry-published'); ?> ><?php echo get_the_date(); ?> </time> <?php comments_popup_link(number_format_i18n(0), number_format_i18n(1), '%', 'comments-link', ''); ?> </div><!-- .entry-byline --> </div><!-- .entry-header --> <div class="entry-media"> <?php get_the_image(array('size' => 'full', 'link_to_post' => false, 'scan_raw' => true, 'scan' => true, 'caption' => true, 'order' => array('scan_raw', 'scan', 'featured', 'attachment'))); ?> </div><!-- .entry-media --> <div <?php hybrid_attr('entry-summary'); ?> > <?php the_excerpt(); ?> <?php tamatebako_read_more(); ?> </div><!-- .entry-summary -->
<?php if (is_page() || is_singular('post') || is_category() || is_tag()) { ?> <?php if (has_post_thumbnail()) { ?> <?php $bgimage = get_the_image(array('format' => 'array', 'size' => 'full')); ?> <?php $bgimage = $bgimage[src]; ?> <?php } else { ?> <?php $images = get_field('header_images', 'option'); ?> <?php $rand = array_rand($images, 1); ?> <?php $bgimage = $images[$rand]['url']; ?> <?php
if (function_exists('ev_post_views')) { ev_post_views(array('text' => '%s')); } ?> <?php edit_post_link(); ?> </footer><!-- .entry-footer --> <?php } else { // If not viewing a single attachment. ?> <?php get_the_image(array('size' => 'stargazer-full', 'order' => array('featured', 'attachment'))); ?> <header class="entry-header"> <?php the_title('<h2 ' . hybrid_get_attr('entry-title') . '><a href="' . get_permalink() . '" rel="bookmark" itemprop="url">', '</a></h2>'); ?> </header><!-- .entry-header --> <div <?php hybrid_attr('entry-summary'); ?> > <?php the_excerpt(); ?>
<div id="post-<?php the_ID(); ?> " class="<?php hybrid_entry_class(); ?> "> <?php do_atomic('open_entry'); // prototype_open_entry ?> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('meta_key' => 'Thumbnail', 'size' => 'thumbnail')); } ?> <?php echo apply_atomic_shortcode('entry_title', '[entry-title]'); ?> <?php echo apply_atomic_shortcode('byline', '<div class="byline">' . __('By [entry-author] on [entry-published] [entry-edit-link before=" | "]', hybrid_get_textdomain()) . '</div>'); ?> <div class="entry-summary"> <?php the_excerpt(); ?>
<?php $slidecount = 1; $args = array('meta_key' => '_oxygen_post_location', 'meta_value' => 'featured', 'post__not_in' => get_option('sticky_posts')); while ($loop->have_posts()) { $loop->the_post(); ?> <li class="<?php echo $slidecount == 6 ? 'last' : ''; ?> "> <?php if (current_theme_supports('get-the-image')) { get_the_image(array('meta_key' => 'Thumbnail', 'size' => 'slider-nav-thumbnail')); } ?> </li> <?php $slidecount++; ?> <?php } ?> </ul>
the_permalink(); ?> " rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?> "><?php the_title(); ?> </a></h6> <p class="postmetadata"><?php the_time('M d, Y'); ?> </p> <?php get_the_image(array('custom_key' => array('thumbnail'), 'default_size' => 'thumbnail', 'width' => '150', 'height' => '150', 'image_class' => '')); ?> <div class="excerpt_small"><p><?php echo substr(get_the_excerpt(), 0, 180); ?> ...</p></div> <?php } wp_reset_query(); ?> <h6 class="category_more"><a href="<?php echo get_category_link($category); ?> ">More News...</a></h6> <?php
function widget($args, $instance) { extract($args); /* User-selected settings. */ $title = apply_filters('widget_title', $instance['title']); $category = $instance['category']; $show_count = $instance['show_count']; $showDate = $instance['datetime']; $showComments = $instance['comments']; /* Before widget (defined by themes). */ echo $before_widget; /* Title of widget (before and after defined by themes). */ if ($title) { echo $before_title . $title . $after_title; } echo '<ul class="posts posts-side">'; $query_opts = apply_filters('wpzoom_query', array('posts_per_page' => $show_count, 'post_type' => 'post')); if ($category) { $query_opts['cat'] = $category; } query_posts($query_opts); if (have_posts()) { while (have_posts()) { the_post(); unset($prev, $image); ?> <li> <article> <?php get_the_image(array('size' => 'recent-posts-widget', 'width' => 60, 'height' => 45, 'before' => '<div class="cover cover-border">', 'after' => '</div>')); ?> <header> <h3><a href="<?php the_permalink(); ?> " title="<?php printf(esc_attr__('Permalink to %s', 'wpzoom'), the_title_attribute('echo=0')); ?> " rel="bookmark"><?php the_title_attribute(); ?> </a></h3> </header> <p class="postmetadata"> <span> <?php if ($showDate == 'on') { ?> <time datetime="<?php the_time("Y-m-d"); ?> " pubdate><?php the_time("jS F Y"); ?> </time><?php $prev = TRUE; } ?> <?php if ($showComments == 'on') { if ($prev) { echo ' / '; } comments_popup_link(__('0 comments', 'wpzoom'), __('1 comment', 'wpzoom'), __('% comments', 'wpzoom'), '', ''); } ?> </span> </p> </article> <div class="cleaner"> </div> </li> <?php } } //Reset query_posts wp_reset_query(); echo '</ul>'; /* After widget (defined by themes). */ echo $after_widget; }
> <?php the_content(); ?> <?php wp_link_pages(); ?> </div><!-- .entry-content --> <?php } else { // If not viewing a single post. ?> <?php get_the_image(array('size' => 'portfolio')); ?> <div <?php hybrid_attr('entry-summary'); ?> > <a href="<?php thds_theme_url(); ?> "> <?php thds_theme_excerpt(); ?> </a> </div><!-- .entry-summary -->
"> <h2 class="title"><a href="<?php the_permalink(); ?> " rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?> "><?php the_title(); ?> </a></h2> <div class="entry"> <?php if (function_exists('get_the_image')) { get_the_image(array('custom_key' => array('post_thumbnail'), 'default_size' => 'full', 'image_class' => 'alignleft', 'width' => '198', 'height' => '166')); } ?> <p><?php truncate_post(380, true); ?> </p> </div> <div class="meta"> <span class="time">Posted on <?php the_time('F d, Y'); ?> </span><a class="more-link" href="<?php the_permalink(); ?> #more">Read More</a>