Advertisement
Guest User

Untitled

a guest
Oct 1st, 2012
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 26.04 KB | None | 0 0
  1. <?php get_header(); ?>
  2. <div id="main-content">
  3. <div id="content1">
  4. <div id="slides_three">
  5. <div class="slides_container">
  6. <?php query_posts('showposts=5&cat='.of_get_option('example_select_categories').'&offset=0'); if (have_posts()) : ?>
  7. <?php while (have_posts()) : the_post(); ?>
  8. <div class="slide slides_threewrap">
  9. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  10. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('secslider'); ?></a>
  11. <?php } else { ?>
  12. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt=" " style="width:302px; height:238px;" /> </a><?php } ?>
  13. <?php endif?>
  14. <?php if(get_option('thumbok')!="yes"):?>
  15. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  16. $m_image = ''; $m_image_def = get_template_directory_uri() . '/img/noimg.png';
  17. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  18. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  19. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 302 . '&amp;h=' . 238 . '&amp;zc=1'; } ?>
  20. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  21. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  22. <?php endif?>
  23. <h2> <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  24. <?php the_content_limit('300'); ?>
  25. <div class="smallgal_meta">On <?php the_time('M j, Y') ?> <b>//</b> in <?php the_category(', ') ?> <b>//</b> <?php comments_popup_link(__('# 0'), __('# 1'), __('# %')); ?></div>
  26. <div class="cb"></div>
  27. </div> <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  28. </div>
  29. </div>
  30. <div id="adblock"> <div class="themidad"> <?php if(get_option('ad3ok')!="yes"):?><?php endif?>
  31. <?php if(get_option('ad3ok')!="no"):?> <?php echo get_option('ad3'); ?> <?php endif?>
  32. </div> </div>
  33. <div class="cb"></div>
  34. </div>
  35. <div id="content2"> <div id="content2block">
  36. <?php
  37. $b1_cat = of_get_option('block2cat');
  38. ?>
  39. <?php /* Category credentials */
  40. $category_id = $b1_cat;
  41. $category_link = get_category_link( $category_id );
  42. $category_name = get_cat_name($category_id);
  43. ?>
  44.  
  45. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  46. <?php while (have_posts()) : the_post(); ?>
  47. <div id="content2wraph3">
  48. <div id="content2wraph3_l">
  49. <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  50. <?php echo of_get_option('block2txt', 'Category Name'); ?></a></div>
  51. <div id="content2wraph3_r">
  52. <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>"><?php _e("More", "nt"); ?> <?php echo of_get_option('block2txt', 'Category Name'); ?> ></a>
  53. </div>
  54. <div class="cb"></div>
  55. </div>
  56. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  57. <div id="content2block_2"> <?php query_posts('showposts=6&cat='.of_get_option('block2cat').'&offset=0'); if (have_posts()) : ?>
  58. <?php while (have_posts()) : the_post(); ?>
  59. <div class="content2wrap">
  60. <h2>
  61. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  62. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('content2'); ?></a>
  63. <?php } else { ?>
  64. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:150px; height:75px;" /> </a><?php } ?>
  65. <?php endif?>
  66. <?php if(get_option('thumbok')!="yes"):?>
  67. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  68. $m_image = '';
  69. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  70. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  71. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 150 . '&amp;h=' . 75 . '&amp;zc=1'; } ?>
  72. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  73. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  74. <?php endif?> <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  75. <div class="cb"></div>
  76. </div>
  77. <?php endwhile; ?> <?php else : ?> <?php endif; ?> </div>
  78. </div> </div>
  79. <div class="themidad"> <?php if(get_option('ad4ok')!="yes"):?><?php endif?>
  80. <?php if(get_option('ad4ok')!="no"):?><center style=" margin-bottom: 11px;"><?php echo get_option('ad4'); ?></center><?php endif?>
  81. </div>
  82. <div id="content">
  83. <div id="smblock1">
  84. <div class="smblock_block">
  85. <?php
  86. $b1_cat = of_get_option('block3cat');
  87. ?>
  88. <?php /* Category credentials */
  89. $category_id = $b1_cat;
  90. $category_link = get_category_link( $category_id );
  91. $category_name = get_cat_name($category_id);
  92. ?>
  93.  
  94. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  95. <?php while (have_posts()) : the_post(); ?>
  96. <div class="smblock1_h3">
  97. <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  98. <b><?php echo of_get_option('block3txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  99. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  100. <div id="smblock1_block_l">
  101. <?php query_posts('showposts=1&cat='.of_get_option('block3cat').'&offset=0'); if (have_posts()) : ?>
  102. <?php while (have_posts()) : the_post(); ?>
  103. <div class="smblock1_wrap">
  104. <h2>
  105. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  106. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock1_block_l'); ?></a>
  107. <?php } else { ?>
  108. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:200px; height:150px;" /> </a><?php } ?>
  109. <?php endif?>
  110. <?php if(get_option('thumbok')!="yes"):?>
  111. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  112. $m_image = '';
  113. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  114. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  115. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 200 . '&amp;h=' . 150 . '&amp;zc=1'; } ?>
  116. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  117. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  118. <?php endif?> <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  119. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,18); ?>..
  120. <div class="cb"></div>
  121. </div>
  122. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  123. </div>
  124. <div id="smblock1_block_r">
  125. <?php query_posts('showposts=2&cat='.of_get_option('block3cat').'&offset=1'); if (have_posts()) : ?>
  126. <?php while (have_posts()) : the_post(); ?>
  127. <div class="smblock1_wrap_r1">
  128. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  129. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  130. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock1_wrap_r1'); ?></a>
  131. <?php } else { ?>
  132. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:81px; height:61px;" /> </a><?php } ?>
  133. <?php endif?>
  134. <?php if(get_option('thumbok')!="yes"):?>
  135. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  136. $m_image = '';
  137. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  138. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  139. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 81 . '&amp;h=' . 61 . '&amp;zc=1'; } ?>
  140. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  141. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  142. <?php endif?>
  143. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,32); ?>...
  144. <div class="cb"></div>
  145. </div>
  146. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  147. <?php query_posts('showposts=2&cat='.of_get_option('block3cat').'&offset=3'); if (have_posts()) : ?>
  148. <?php while (have_posts()) : the_post(); ?>
  149. <div class="smblock1_wrap_r2">
  150. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  151. </div>
  152. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  153. </div>
  154. <div class="cb"></div>
  155. </div>
  156. </div>
  157. <div id="smblock2">
  158. <div class="smblock_block">
  159. <?php
  160. $b1_cat = of_get_option('block4cat');
  161. ?>
  162. <?php /* Category credentials */
  163. $category_id = $b1_cat;
  164. $category_link = get_category_link( $category_id );
  165. $category_name = get_cat_name($category_id);
  166. ?>
  167.  
  168. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  169. <?php while (have_posts()) : the_post(); ?>
  170. <div class="smblock1_h3">
  171. <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  172. <b><?php echo of_get_option('block4txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  173. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  174. <div id="smblock2_block_l">
  175. <?php query_posts('showposts=1&cat='.of_get_option('block4cat').'&offset=0'); if (have_posts()) : ?>
  176. <?php while (have_posts()) : the_post(); ?>
  177. <div class="smblock2_wrap">
  178. <h2>
  179. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  180. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock2_block_l'); ?></a>
  181. <?php } else { ?>
  182. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:328px; height:181px;" /> </a><?php } ?>
  183. <?php endif?>
  184. <?php if(get_option('thumbok')!="yes"):?>
  185. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  186. $m_image = '';
  187. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  188. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  189. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 328 . '&amp;h=' . 181 . '&amp;zc=1'; } ?>
  190. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  191. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  192. <?php endif?> <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  193. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,18); ?>..
  194. <div class="cb"></div>
  195. </div>
  196. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  197. </div>
  198. <div id="smblock2_block_r">
  199. <?php query_posts('showposts=2&cat='.of_get_option('block4cat').'&offset=1'); if (have_posts()) : ?>
  200. <?php while (have_posts()) : the_post(); ?>
  201. <div class="smblock2_wrap_r1">
  202. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  203. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  204. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock1_wrap_r1'); ?></a>
  205. <?php } else { ?>
  206. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:81px; height:61px;" /> </a><?php } ?>
  207. <?php endif?>
  208. <?php if(get_option('thumbok')!="yes"):?>
  209. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  210. $m_image = '';
  211. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  212. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  213. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 81 . '&amp;h=' . 61 . '&amp;zc=1'; } ?>
  214. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  215. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  216. <?php endif?>
  217. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,25); ?>...
  218. <div class="cb"></div>
  219. </div>
  220. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  221. </div>
  222. <div class="cb"></div>
  223. </div>
  224. </div>
  225. <div id="smblock3">
  226. <div class="smblock_block">
  227. <?php
  228. $b1_cat = of_get_option('block5cat');
  229. ?>
  230. <?php /* Category credentials */
  231. $category_id = $b1_cat;
  232. $category_link = get_category_link( $category_id );
  233. $category_name = get_cat_name($category_id);
  234. ?>
  235.  
  236. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  237. <?php while (have_posts()) : the_post(); ?>
  238. <div class="smblock1_h3"> <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  239. <b><?php echo of_get_option('block5txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  240. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  241. <div id="smblock3_block_l">
  242. <?php query_posts('showposts=1&cat='.of_get_option('block5cat').'&offset=0'); if (have_posts()) : ?>
  243. <?php while (have_posts()) : the_post(); ?>
  244. <div class="smblock3_wrap">
  245. <h2> <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  246. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  247. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock3_block_l'); ?></a>
  248. <?php } else { ?>
  249. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:284px; height:190px;" /> </a><?php } ?>
  250. <?php endif?>
  251. <?php if(get_option('thumbok')!="yes"):?>
  252. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  253. $m_image = '';
  254. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  255. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  256. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 284 . '&amp;h=' . 190 . '&amp;zc=1'; } ?>
  257. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  258. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  259. <?php endif?> <div class="cb"></div> </div>
  260. <?php endwhile; ?> <?php else : ?> <?php endif; ?> </div>
  261. <div id="smblock3_block_r"><ul>
  262. <?php query_posts('showposts=8&cat='.of_get_option('block5cat').'&offset=1'); if (have_posts()) : ?>
  263. <?php while (have_posts()) : the_post(); ?>
  264. <li class="smblock3_wrap_r1"><h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2></li>
  265. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  266. </ul> </div> <div class="cb"></div> </div> </div>
  267. <div id="smblock4">
  268. <div class="smblock_block">
  269. <?php
  270. $b1_cat = of_get_option('block6cat');
  271. ?>
  272. <?php /* Category credentials */
  273. $category_id = $b1_cat;
  274. $category_link = get_category_link( $category_id );
  275. $category_name = get_cat_name($category_id);
  276. ?>
  277.  
  278. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  279. <?php while (have_posts()) : the_post(); ?>
  280. <div class="smblock1_h3"> <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  281. <b><?php echo of_get_option('block6txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  282. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  283. <div id="smblock4_block_r"> <ul>
  284. <?php query_posts('showposts=2&cat='.of_get_option('block6cat').'&offset=0'); if (have_posts()) : ?>
  285. <?php while (have_posts()) : the_post(); ?>
  286. <li class="smblock4_wrap_r1">
  287. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  288. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  289. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock4_block_l'); ?></a>
  290. <?php } else { ?>
  291. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:99px; height:66px;" /> </a><?php } ?>
  292. <?php endif?>
  293. <?php if(get_option('thumbok')!="yes"):?>
  294. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  295. $m_image = '';
  296. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  297. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  298. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 99 . '&amp;h=' . 66 . '&amp;zc=1'; } ?>
  299. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  300. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  301. <?php endif?>
  302. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,23); ?>...
  303. <div class="cb"></div>
  304. </li>
  305. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  306. </ul> </div>
  307. <div class="cb"></div> </div> </div>
  308. <div id="smblock5">
  309. <div class="smblock_block">
  310. <?php
  311. $b1_cat = of_get_option('block7cat');
  312. ?>
  313. <?php /* Category credentials */
  314. $category_id = $b1_cat;
  315. $category_link = get_category_link( $category_id );
  316. $category_name = get_cat_name($category_id);
  317. ?>
  318.  
  319. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  320.  
  321. <?php while (have_posts()) : the_post(); ?>
  322. <div class="smblock1_h3"> <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  323. <b><?php echo of_get_option('block7txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  324. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  325. <div class="smblock5_left">
  326. <div id="smblock5_block_r"> <ul>
  327. <?php query_posts('showposts=3&cat='.of_get_option('block7cat').'&offset=0'); if (have_posts()) : ?>
  328. <?php while (have_posts()) : the_post(); ?>
  329. <li class="smblock5_wrap_r1">
  330. <div class="smblock5_wrap_r1_l">
  331. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  332. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock5_block_l'); ?></a>
  333. <?php } else { ?>
  334. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:129px; height:67px;" /> </a><?php } ?>
  335. <?php endif?>
  336. <?php if(get_option('thumbok')!="yes"):?>
  337. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  338. $m_image = '';
  339. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  340. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  341. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 129 . '&amp;h=' . 67 . '&amp;zc=1'; } ?>
  342. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  343. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  344. <?php endif?> </div> <div class="smblock5_wrap_r1_r">
  345. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2> <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,21); ?>...</div>
  346. <div class="cb"></div>
  347. </li> <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  348. </ul> </div>
  349. </div>
  350. <div class="smblock5_right">
  351. <?php query_posts('showposts=1&cat='.of_get_option('block7cat').'&offset=3'); if (have_posts()) : ?>
  352. <?php while (have_posts()) : the_post(); ?>
  353. <div class="smblock5_right_in">
  354. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  355. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,35); ?>...
  356. </div> <?php endwhile; ?> <?php else : ?> <?php endif; ?> </div> <div class="cb"></div> </div> </div>
  357. <div id="smblock6">
  358. <div class="smblock_block">
  359. <?php
  360. $b1_cat = of_get_option('block8cat');
  361. ?>
  362. <?php /* Category credentials */
  363. $category_id = $b1_cat;
  364. $category_link = get_category_link( $category_id );
  365. $category_name = get_cat_name($category_id);
  366. ?>
  367.  
  368. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  369. <?php while (have_posts()) : the_post(); ?>
  370. <div class="smblock1_h3"> <a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  371. <b><?php echo of_get_option('block8txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  372. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  373. <div id="smblock6_block_l">
  374. <?php query_posts('showposts=4&cat='.of_get_option('block8cat').'&offset=0'); if (have_posts()) : ?>
  375. <?php while (have_posts()) : the_post(); ?>
  376. <div class="smblock6_wrap">
  377. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  378. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock6_block_l'); ?></a>
  379. <?php } else { ?>
  380. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:138px; height:104px;" /> </a><?php } ?>
  381. <?php endif?>
  382. <?php if(get_option('thumbok')!="yes"):?>
  383. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  384. $m_image = '';
  385. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  386. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  387. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 138 . '&amp;h=' . 104 . '&amp;zc=1'; } ?>
  388. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  389. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  390. <?php endif?> <h2> <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  391. <div class="cb"></div> </div> <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  392. </div> <div class="cb"></div> </div> </div>
  393. <div id="smblock7">
  394. <div class="smblock_block">
  395. <?php
  396. $b1_cat = of_get_option('block9cat');
  397. ?>
  398. <?php /* Category credentials */
  399. $category_id = $b1_cat;
  400. $category_link = get_category_link( $category_id );
  401. $category_name = get_cat_name($category_id);
  402. ?>
  403.  
  404. <?php query_posts('showposts=1&cat='. $category_id); if (have_posts()) : ?>
  405. <?php while (have_posts()) : the_post(); ?>
  406. <div class="smblock1_h3"><a href="<?php echo ($category_link); ?>" title="<?php echo $category[0]->category_nicename; ?>">
  407. <b><?php echo of_get_option('block9txt', 'Category Name'); ?></b> <?php _e("NEWS", "nt"); ?></a></div>
  408. <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  409.  
  410. <div id="smblock7_block_r">
  411. <?php query_posts('showposts=4&cat='.of_get_option('block9cat').'&offset=0'); if (have_posts()) : ?>
  412. <?php while (have_posts()) : the_post(); ?>
  413. <div class="smblock7_wrap_r1">
  414. <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
  415. <?php if(get_option('thumbok')!="no"):?> <?php if( has_post_thumbnail() ) { ?>
  416. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('smblock1_wrap_r1'); ?></a>
  417. <?php } else { ?>
  418. <a href="<?php the_permalink(); ?>"> <img src="<?php bloginfo('template_directory'); ?>/img/noimg.png" alt="" style="width:81px; height:61px;" /> </a><?php } ?>
  419. <?php endif?>
  420. <?php if(get_option('thumbok')!="yes"):?>
  421. <?php $m_scrp = get_template_directory_uri() . '/includes/timthumb.php?';
  422. $m_image = '';
  423. $customfields = get_post_custom(); if (empty($customfields['image'][0])) {
  424. $m_image = m_theme_capture_first_image(); } else { $m_image = $customfields['image'][0]; } if (empty($m_image)) { $imgpath = $m_image_def; } else {
  425. $imgpath = $m_scrp . 'src=' . $m_image . '&amp;w=' . 81 . '&amp;h=' . 61 . '&amp;zc=1'; } ?>
  426. <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
  427. <img src="<?php echo $imgpath; ?>" alt="" /> </a>
  428. <?php endif?>
  429. <?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,15); ?>..
  430. <div class="cb"></div>
  431. </div> <?php endwhile; ?> <?php else : ?> <?php endif; ?>
  432. <div class="clr"></div> </div> <div class="cb"></div> </div> </div>
  433. </div>
  434. <?php include(TEMPLATEPATH . '/sidebar.php'); ?>
  435. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement