1. <?php
  2. /**
  3. * The template used to display Tag Archive pages
  4. *
  5. * @package WordPress
  6. * @subpackage Twenty_Eleven
  7. * @since Twenty Eleven 1.0
  8.  
  9. Template Name: Tag Page*/
  10. get_header(); ?>
  11.  
  12. <div class="content">
  13. <div class="main">
  14. <div class="leftpart">
  15. <div class="navigation">
  16. <?php if(function_exists('bcn_display'))
  17. {
  18. bcn_display();
  19. }?>
  20.  
  21. </div>
  22. <div class="tourslist">
  23. <div>
  24.  
  25. <ul>
  26. <li class="tourslist_li" style="list-style:none">
  27. <div class="tourheadding" style="background:none">
  28. <div class="headdingleft">
  29. <h3>
  30. <?php echo "Архив Тегов: ". $term; ?>
  31. </h3>
  32. </div>
  33. <div class="tourprice helvetica-neue-light">
  34. &nbsp;
  35. </div>
  36. </div>
  37. </li>
  38. </ul>
  39.  
  40. </div>
  41. <?php if ( have_posts() ) : ?>
  42. <ul>
  43. <?php
  44. while (have_posts() ) : the_post();
  45.  
  46. //global $post;
  47. //$pst_id = $post->ID;
  48.  
  49. ?>
  50. <?php $meta = get_post_meta($post->ID, 'abg_tours_download_brochure', true); ?>
  51. <?php $tourimg = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ) ,'list-thumb'); ?>
  52. <li class="tourslist_li" style="list-style:none">
  53. <div class="tourheadding">
  54. <div class="headdingleft">
  55. <h3><a href="<?php the_permalink(); ?>">
  56. <?php the_title(); ?>
  57. </a> </h3>
  58. <p><?php echo get_post_meta($post->ID,'abg_tours_days_nights',true); ?></p>
  59. </div>
  60. <div class="tourprice helvetica-neue-light">
  61. <?php if(get_post_meta($post->ID,'abg_tours_price',true)) { ?>
  62. <img src="<?php bloginfo('template_url'); ?>/images/from_ru.png" /> $<?php echo get_post_meta($post->ID,'abg_tours_price',true);?>
  63. <?php } ?>
  64. </div>
  65. </div>
  66. <div class="toursdetail">
  67. <?php if($tourimg[0]) {?><div class="placeimage"><a href="<?php the_permalink(); ?>"> <span class="newimg"></span>
  68. <img src="<?php echo $tourimg[0]; ?>" width="241" height="139" alt="" /> </a> </div><?php } ?>
  69. <div class="<?php if($tourimg[0]) {?>toursright<?php }else{ ?>toursright2<?php } ?>">
  70. <div class="citylist">
  71. <p><strong>Тип Тура:</strong></p>
  72. <p>
  73. <?php $terms = get_the_terms($post->ID, 'tourstype');
  74. $types = '';
  75. foreach($terms as $tourtype ){
  76. if($tourtype->taxonomy == 'tourstype' ){
  77. $types[] = $tourtype->name;
  78. }
  79. }
  80.  
  81. echo implode(", ",$types);
  82.  
  83. ?>
  84. </p>
  85. </div>
  86. <div class="citylist">
  87. <p><strong>Города:</strong></p>
  88. <p>
  89. <?php $terms1 = get_the_terms($post->ID, 'tourscat');
  90. $cities = '';
  91. foreach($terms1 as $tourcity ){
  92. $cities[] = $tourcity->name;
  93. }
  94. echo implode(", ",$cities);
  95. ?>
  96. </p>
  97. </div>
  98. <div class="description">
  99. <h5>Описание:</h5>
  100. <p><?php echo substr(get_the_content(),0,145); ?></p>
  101. </div>
  102. <div class="tourshare"> <span class='st_email_large' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Отправить имайл' style="float:left; padding-top:6px !important;">Отправить имайл</span> <span class="float-left" style="padding-top:5px !important;">|</span> <span class='st_sharethis' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' style="padding-left:-10px;" displayText='Поделиться'></span> <span class="float-left" style="padding-top:5px !important;">|</span> <a href="<?php the_permalink(); ?>" class="moredetail">Детали Тура</a> </div>
  103. </div>
  104. </div>
  105. </li>
  106. <!-- #post-<?php the_ID(); ?> -->
  107.  
  108. <?php endwhile; // end of the loop. ?>
  109. </ul>
  110. <?php else : ?>
  111. <ul>
  112. <li class="tourslist_li" style="list-style:none; min-height:200px;">
  113. <article id="post-0" class="post no-results not-found">
  114. <header class="entry-header">
  115. <h1 class="entry-title">
  116. <?php _e( 'Nothing Found', 'twentyeleven' ); ?>
  117. </h1>
  118. </header>
  119. <!-- .entry-header -->
  120.  
  121. <div class="entry-content">
  122. <p>
  123. <?php _e( 'Apologies, but no results were found for the requested archive. Perhaps searching will help find a related post.', 'twentyeleven' ); ?>
  124. </p>
  125. <?php get_search_form(); ?>
  126. </div>
  127. <!-- .entry-content -->
  128. </article>
  129. <!-- #post-0 -->
  130. </li>
  131. </ul>
  132. <?php endif;
  133.  
  134. ?>
  135. </div>
  136. <div class="pagi" style="position:relative">
  137. <?php //kriesi_pagination(); ?>
  138. <?php wp_pagenavi();
  139. ?>
  140. </div>
  141. </div>
  142. <?php get_sidebar(); ?>
  143. </div>
  144. </div>
  145.  
  146. <?php get_footer(); ?>