</a> </h1> <?php Mirano_Theme::road_entry_meta_small(); ?> <?php } ?> </header> <?php if (is_single()) { ?> <div class="entry-meta"> <?php Mirano_Theme::road_entry_meta(); ?> </div> <?php } ?> <?php if (is_single()) { ?> <div class="entry-content"> <?php the_content(esc_html__('Continue reading <span class="meta-nav">→</span>', 'mirano')); ?> <?php wp_link_pages(array('before' => '<div class="page-links">' . esc_html__('Pages:', 'mirano'), 'after' => '</div>', 'pagelink' => '<span>%</span>'));
public function widget($args, $instance) { global $post, $road_opt; $title = apply_filters('widget_title', $instance['title']); // before and after widget arguments are defined by themes echo wp_kses($args['before_widget'], array('aside' => array('id' => array(), 'class' => array()))); if (!empty($title)) { echo wp_kses($args['before_title'] . $title . $args['after_title'], array('aside' => array('id' => array(), 'class' => array()), 'h3' => array('class' => array()), 'span' => array('class' => array()))); } switch ($instance['type']) { case 'recent_posts': $postargs = array('posts_per_page' => $instance['amount'], 'order' => 'DESC', 'orderby' => 'post_date'); $postslist = get_posts($postargs); ?> <div class="recent-posts"> <ul> <?php foreach ($postslist as $post) { setup_postdata($post); ?> <li> <div class="post-wrapper"> <div class="post-thumb"> <a href="<?php the_permalink(); ?> "><?php the_post_thumbnail(array(50, 50)); ?> </a> </div> <div class="post-info"> <h3 class="post-title"><a href="<?php the_permalink(); ?> "><?php the_title(); ?> </a></h3> <div class="post-date"> <?php echo get_the_date(); ?> </div> </div> </div> </li> <?php } ?> </ul> </div> <?php wp_reset_postdata(); break; case 'popular_posts': $postargs = array('posts_per_page' => $instance['amount'], 'order' => 'DESC', 'orderby' => 'comment_count'); $postslist = get_posts($postargs); ?> <div class="recent-posts"> <ul> <?php foreach ($postslist as $post) { setup_postdata($post); ?> <li> <div class="post-wrapper"> <div class="post-thumb"> <a href="<?php the_permalink(); ?> "><?php the_post_thumbnail(array(50, 50)); ?> </a> </div> <div class="post-info"> <h3 class="post-title"><a href="<?php the_permalink(); ?> "><?php the_title(); ?> </a></h3> <div class="post-date"> <?php echo get_the_date(); ?> </div> </div> </div> </li> <?php } ?> </ul> </div> <?php wp_reset_postdata(); break; case 'recent_comments': $commentargs = array('status' => 'approve', 'post_type' => 'post', 'number' => $instance['amount']); $comments = get_comments($commentargs); ?> <ul> <?php foreach ($comments as $comment) { ?> <li> <div class="post-wrapper"> <div class="post-thumb"> <?php echo get_avatar($comment->comment_author_email, 50, '', ''); ?> </div> <div class="post-info"> <p><?php echo esc_html($comment->comment_author); ?> <?php esc_html_e('says', 'mirano'); ?> :</p> <a href="<?php echo get_comments_link($comment->comment_post_ID); ?> " title="<?php echo esc_attr($comment->comment_author . ' on ' . get_the_title($comment->comment_post_ID)); ?> "><?php echo Mirano_Theme::roadlimitStringByWord($comment->comment_content, 30, '...'); ?> </a> </div> </div> </li> <?php } ?> </ul> <?php break; } echo wp_kses($args['after_widget'], array('aside' => array('id' => array(), 'class' => array()), 'h3' => array('class' => array()), 'span' => array('class' => array()))); }
<?php while (have_posts()) { the_post(); ?> <?php get_template_part('content', get_post_format()); ?> <?php } ?> <div class="pagination"> <?php Mirano_Theme::road_pagination(); ?> </div> <?php } else { ?> <?php get_template_part('content', 'none'); ?> <?php } ?> </div> </div> <?php
* * Description: About page template * * @package WordPress * @subpackage Road_Themes * @since Road Themes 1.0 */ global $road_opt; get_header(); ?> <div class="main-container about-page"> <div class="page-content"> <div class="container"> <?php Mirano_Theme::road_breadcrumb(); ?> </div> <?php while (have_posts()) { the_post(); ?> <?php get_template_part('content', 'page'); ?> <?php } // end of the loop. ?> </div>