-
Notifications
You must be signed in to change notification settings - Fork 0
/
category-nation.php
135 lines (97 loc) · 4.52 KB
/
category-nation.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
<?php get_header(); ?>
<!-- ******************** begin scroller ******************** -->
<div id="featured-noslide">
<?php $imageCounter = 1; ?>
<?php query_posts('showposts=1&category_name=nation-category-slider'); ?>
<?php while ( have_posts() ) : the_post(); ?>
<a href="<?php the_permalink(); ?>"><img src="<?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'category-image'); ?>" rel="caption-<?php echo $imageCounter; ?>" /></a>
<?php $imageCounter+=1; ?>
<?php endwhile; ?>
<?php rewind_posts(); ?>
<?php wp_reset_query(); ?>
<?php $imageCounter = 1; ?>
<?php query_posts('showposts=1&category_name=nation-category-slider'); ?>
<?php while ( have_posts() ) : the_post(); ?>
<span id="credit-<?php echo $imageCounter; ?>" class="photo-credit"><?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'photo-credit'); ?></span>
<?php endwhile; ?>
<?php rewind_posts(); ?>
<?php wp_reset_query(); ?>
<?php $imageCounter = 1; ?>
<?php query_posts('showposts=1&category_name=nation-category-slider'); ?>
<?php while ( have_posts() ) : the_post(); ?>
<span class="orbit-caption" id="caption-<?php echo $imageCounter; ?>"><a href="<?php the_permalink(); ?>"><p class="head"><?php the_title(); ?></p><p class="subhead"><?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'subhead'); ?></p><span class="arrows">>>></span><span class="featured-more">FULL STORY</span></a></span>
<?php $imageCounter++; ?>
<?php endwhile; ?>
<?php rewind_posts(); ?>
<?php wp_reset_query(); ?>
<div id="slider-blue"></div>
</div>
<div class="clear"></div>
<!-- ******************** begin content ******************** -->
<div id="content" class="grid_16">
<!-- @@@ begin left bar @@@ -->
<div id="leftBar" class="grid_5">
<?php query_posts('showposts=6&category_name=nation-left'); ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php global $post; ?>
<div class="news element">
<div class="topGutter">
<a href="<?php the_permalink(); ?>"><p class="head"><?php the_title(); ?></p>
<p class="subhead"><?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'subhead'); ?></p></a>
</div>
<div class="imageHolder">
<div class="boxgrid captionfull">
<a href="<?php the_permalink(); ?>"><img src="<?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'category-image'); ?>" /></a>
<div class="cover boxcaption">
<?php the_excerpt(); ?>
</div>
</div>
</div>
</div>
<?php endwhile; ?>
<?php rewind_posts(); ?>
<?php wp_reset_query(); ?>
</div><!-- end left bar -->
<!-- @@@ begin text featured stories @@@ -->
<div id="featured_text" class="grid_11">
<ul>
<!-- pulls a list of posts from category 'featured_text' into list items -->
<?php
global $post;
$tmp_post = $post;
$post_num = 0; //var so we can give classes depending on li position
$myposts = get_posts('numberposts=3&offset=0&category_name=nation-featured-text');
foreach($myposts as $post) :
setup_postdata($post);
$post_num++;
?>
<li class="<?php if($post_num==3) { echo "last"; } else { echo "normal"; } ?>"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></li>
<?php endforeach; ?>
<?php $post = $tmp_post; ?>
</ul>
</div>
<!-- @@@ begin middle bar @@@ -->
<div id="middleBar" class="grid_7">
<?php query_posts('showposts=4&category_name=nation-middle'); ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php global $post; ?>
<div class="news element">
<div class="topGutter">
<a href="<?php the_permalink(); ?>"><p class="head"><?php the_title(); ?></p>
<p class="subhead"><?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'subhead'); ?></p></a>
</div>
<div class="imageHolder">
<div class="boxgrid captionfull">
<a href="<?php the_permalink(); ?>"><img src="<?php if ( function_exists('the_DifferentTypeFacts') ) the_DifferentTypeFacts($post->ID, 'category-image'); ?>" /></a>
<div class="cover boxcaption">
<?php the_excerpt(); ?>
</div>
</div>
</div>
</div>
<?php endwhile; ?>
<?php rewind_posts(); ?>
<?php wp_reset_query(); ?>
</div><!--end middleBar -->
<?php get_sidebar(); ?>
<?php get_footer(); ?>