Advertisement
Guest User

Untitled

a guest
Jan 16th, 2012
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.40 KB | None | 0 0
  1. <div class="content">
  2. <div class="postMargin"></div>
  3. <div class="pageWrapper">
  4. <?php query_posts( 'post_type=ministries'); ?>
  5. <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
  6. <?php
  7. $title= str_ireplace('"', '', trim(get_the_title()));
  8. $desc= str_ireplace('"', '', trim(get_the_content()));
  9. ?>
  10. <!-- beginning of custom post loop --!>
  11.  
  12. <div class="cptWrapper">
  13.  
  14. <h2 class="postTitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title(); ?>"><?php the_title(); ?></a></h2>
  15. <div class="cptHead">
  16. <div class="cptImage"><?php the_post_thumbnail();?>
  17. </div>
  18. <div>
  19.  
  20. <?php $the_website= get_post_custom_values('ministry_website');
  21. if($the_website[0] != ""){
  22.  
  23. ?>
  24. <p><span class="infoLabel">Website:</span> <span class="infoData"><a href="http://<?=$the_website[0]?>"><?=$the_website[0]?></a><span><br />
  25.  
  26. <?php }else{ ?>
  27. <p> <span class="infoLabel">Website:</span> <span class="infoData">None Listed</span><br />
  28. <?php } ?>
  29.  
  30. <?php $the_phone= get_post_custom_values('ministry_phone');
  31. if($the_phone[0] != ""){
  32.  
  33. ?>
  34. <span class="infoLabel">Phone:</span> <span class="infoData"><?=$the_phone[0]?></span><br />
  35.  
  36. <?php }else{ ?>
  37. <span class="infoLabel">Phone:</span> <span class="infoData">None Listed</span><br />
  38. <?php } ?>
  39.  
  40. <?php $the_email= get_post_custom_values('ministry_email');
  41. if($the_email[0] != ""){
  42.  
  43. ?>
  44. <span class="infoLabel">Email:</span> <span class="infoData"><a href="mailto:<?=$the_email[0]?>"><?=$the_email[0]?></a></span><br />
  45.  
  46. <?php }else{ ?>
  47. <span class="infoLabel">Email:</span> <span class="infoData">None Listed</span><br />
  48. <?php } ?>
  49.  
  50. <?php $the_location= get_post_custom_values('ministry_location');
  51. if($the_location[0] != ""){
  52.  
  53. ?>
  54. <span class="infoLabel">Location:</span> <span class="infoData"><?=$the_location[0]?></span><br /></p>
  55.  
  56. <?php }else{ ?>
  57. <span class="infoLabel">Location:</span> <span class="infoData">None Listed</span><br /></p>
  58. <?php } ?>
  59.  
  60. </div>
  61.  
  62. <?php the_content(__('Read more'));?>
  63. <?php endwhile; ?>
  64.  
  65. </div>
  66. <div class="navigation">
  67. <div class="alignleft icn-left"><?php next_posts_link('&laquo; Previous entries') ?></div>
  68. <div class="alignright icn-right"><?php previous_posts_link('Next entries &raquo;') ?></div>
  69. <div class="clear"></div>
  70. </div>
  71. </div>
  72.  
  73. <?php else: ?>
  74. <h2>No Results</h2>
  75. <p class="icn-search">Please feel free to try again!<p/>
  76. <div id="searchArrow"></div>
  77. <p class="icn-home">Go back to the <a href="<?php echo get_option('home'); ?>/">frontpage</a>.<p/>
  78. <?php endif; ?>
  79.  
  80. </div>
  81.  
  82. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement