<?php if (get_arclite_option('threecol') || is_page_template('page-3col.php')) { ?> <!-- secondary sidebar --> <div class="col3"> <ul id="sidebar-secondary"> <?php if (function_exists('dynamic_sidebar') && dynamic_sidebar('Secondary sidebar')) { } else { ?> <li class="block"> <div class="info-text"> <p><?php _e("You enabled the secondary sidebar. Add widgets here from the Dashboard", "arclite"); ?> </p> </div> </li> <?php } ?> </ul> </div> <!-- /secondary sidebar --> <?php }
?> | <?php comments_popup_link(__('No Comments', 'arclite'), __('1 Comment', 'arclite'), __('% Comments', 'arclite'), 'comments', __('Comments off', 'arclite')); ?> <?php edit_post_link(__('Edit', 'arclite'), ' | '); ?> </span> </p> </div> <div class="post-content clearfix"> <?php if (get_arclite_option('post_preview') == 'excerpt') { the_excerpt(); } else { the_content(__('Read the rest of this entry »', 'arclite')); } ?> <?php $posttags = get_the_tags(); if ($posttags) { ?> <p class="tags"> <?php the_tags(__('Tags:', 'arclite') . ' ', ', ', ''); ?> </p> <?php }
?> <li id="nav-homelink"><a class="fadeThis" href="<?php echo get_option('home'); ?> " title="<?php _e('Click for Home', 'arclite'); ?> "><span><?php _e('Home', 'arclite'); ?> </span></a></li> <?php } } ?> <?php if (get_arclite_option('navigation') == 'categories') { echo preg_replace('@\\<li([^>]*)>\\<a([^>]*)>(.*?)\\<\\/a>@i', '<li$1><a class="fadeThis"$2><span>$3</span></a>', wp_list_categories('show_count=0&echo=0&title_li=' . get_arclite_option('navigation_exclude'))); } else { echo preg_replace('@\\<li([^>]*)>\\<a([^>]*)>(.*?)\\<\\/a>@i', '<li$1><a class="fadeThis"$2><span>$3</span></a>', wp_list_pages('echo=0&orderby=name&title_li=&exclude=' . get_arclite_option('navigation_exclude'))); } ?> </ul> </div> </div> <!-- /main navigation --> </div> </div> <!-- /header -->
</div> <!-- /page block --> </div> <!-- /footer --> </div> <!-- /page --> <script type="text/javascript"> /* <![CDATA[ */ var isIE6 = false; /* <- do not change! */ var isIE = false; /* <- do not change! */ var lightbox = <?php echo get_arclite_option('lightbox'); ?> ;/* <- do not change! */ /* ]]> */ </script> <!--[if lte IE 6]> <script type="text/javascript"> isIE6 = true; isIE = true; </script> <![endif]--> <!--[if gte IE 7]> <script type="text/javascript"> isIE = true; </script> <![endif]--> <?php wp_footer(); ?> </body> </html>
function queryposts($atts) { extract(shortcode_atts(array('category_id' => '', 'category_name' => '', 'tag' => '', 'day' => '', 'month' => '', 'year' => '', 'count' => '5', 'author_id' => '', 'author_name' => '', 'order_by' => 'date'), $atts)); $output = ''; $query = array(); if ($category_id != '') { $query[] = 'cat=' . $category_id; } if ($category_name != '') { $query[] = 'category_name=' . $category_name; } if ($tag != '') { $query[] = 'tag=' . $tag; } if ($day != '') { $query[] = 'day=' . $day; } if ($month != '') { $query[] = 'monthnum=' . $month; } if ($year != '') { $query[] = 'year=' . $year; } if ($count) { $query[] = 'posts_per_page=' . $count; } if ($author_id != '') { $query[] = 'author=' . $author_id; } if ($author_name != '') { $query[] = 'author_name=' . $author_name; } if ($order_by) { $query[] = 'orderby=' . $order_by; } $posts = new WP_Query(implode('&', $query)); while ($posts->have_posts()) { $posts->the_post(); $output .= '<div class="post">'; $output .= '<div class="post-header"><h3 class="post-title"><a href="' . get_permalink() . '" rel="bookmark" title="' . __('Permanent Link:', 'arclite') . ' ' . get_the_title() . '">' . get_the_title() . '</a></h3>'; $output .= '<p class="post-date"><span class="month">' . get_the_time(__('M', 'arclite')) . '</span><span class="day">' . get_the_time(__('j', 'arclite')) . '</span></p>'; $output .= '<p class="post-author"><span class="info">' . sprintf(__('Posted by %s in %s', 'arclite'), '<a href="' . get_author_posts_url(get_the_author_ID()) . '" title="' . sprintf(__("Posts by %s", "arclite"), attribute_escape(get_the_author())) . ' ">' . get_the_author() . '</a>', get_the_category_list(', ')) . ' | '; if (comments_open()) { // global $id, $comment; $comments_number = get_comments_number(); $output .= '<a href="' . get_permalink() . '#comments" class="'; if ($comments_number == 0) { $output .= 'no '; } $output .= 'comments">'; if ($comments_number > 1) { $output .= sprintf(__('%s comments'), $comments_number); } else { if ($comments_number == 1) { $output .= __('1 comment'); } else { $output .= __('No comments'); } } $output .= '</a>'; } else { $output .= __("Comments Off", "arclite"); } $output .= '</span></p></div>'; $output .= '<div class="post-content clearfix">'; $post_preview = get_arclite_option('post_preview'); if ($post_preview == 'excerpt') { $output .= get_the_excerpt(); } else { $output .= get_the_content(__('Read the rest of this entry »', 'arclite')); } $output .= '</div>'; $post_tags = get_the_tags(); if ($post_tags) { $output .= '<p class="tags">'; $tags = array(); $i = 0; foreach ($post_tags as $tag) { $tags[$i] .= '<a href="' . get_tag_link($tag->term_id) . '" rel="tag" title="' . sprintf(__('%s (%s topics)'), $tag->name, $tag->count) . '">' . $tag->name . '</a>'; $i++; } $output .= implode(', ', $tags); $output .= '</p>'; } $output .= '</div>'; } return $output; }
} ?> </div> </li> <?php } ?> <?php if (get_arclite_option('sidebar_categories')) { ?> <li class="block"> <!-- sidebar menu (categories) --> <ul class="menu"> <?php if (!get_arclite_option('jquery')) { echo preg_replace('@\\<li([^>]*)>\\<a([^>]*)>(.*?)\\<\\/a>@i', '<li$1><a class="fadeThis"$2>$3</a>', wp_list_categories('show_count=0&echo=0&title_li=')); } else { echo preg_replace('@\\<li([^>]*)>\\<a([^>]*)>(.*?)\\<\\/a> \\(\\<a ([^>]*) ([^>]*)>(.*?)\\<\\/a>\\)@i', '<li $1><a class="fadeThis"$2>$3</a><a class="rss tip" $4></a>', wp_list_categories('show_count=0&echo=0&title_li=&feed=XML')); } if (function_exists('xili_language_list')) { xili_language_list(); } ?> </ul> <!-- /sidebar menu --> </li> <?php } ?>