Project

General

Profile

Support #2249 » single.php

erin glass, 2012-11-26 04:29 PM

 
1
<?php get_header(); ?>
2

    
3
	<!--SITE CONTENTS-->
4
	<div id="site-contents">
5

    
6
		<h2 class="ptitle">
7
			<?php
8
			if(get_option('luna_hide_welcome')!="true") {
9
				?>
10
				<!--SLIDE TEXT-->
11
				<div class="slide-text">
12
					<h1><?php echo get_option( 'luna_welcome_title' ); ?></h1>
13
					<span class="subtext"><?php echo get_option( 'luna_welcome_subtitle' ); ?></span>
14
				</div>
15
				<?php
16
			}
17
		?>
18
			<?php $pages = get_page_by_path( 'blog', 'page' ); ?>
19
			<label><?php echo get_post_meta( $pages->ID, "subtitle", true ); ?></label>
20
		</h2>
21

    
22
		<!--INSIDE CONTENT-->
23
		<div class="inside-content clear">
24

    
25
			<!--LEFT CONTAINER-->
26

    
27
			<?php
28
				if(get_option( 'luna_blog_sidebar_type' ) == "Right") {
29
					?><div class="left-container"><?php
30
				}elseif(get_option( 'luna_blog_sidebar_type' ) == "Left") {
31
					?><div class="right left-container"><?php
32
				}else {
33
					?><div class="left-container"><?php
34
				}
35
			?>
36

    
37
				<!--BLOG LIST-->
38
				<div class="blog-list">
39
					<h5><?php if(get_option('luna_hblog_header')!="") { echo get_option('luna_hblog_header'); } else { _e( 'Blog Posts', 'luna_lang' ); } ?></h5>
40
					<?php
41
						while (have_posts()) : the_post();
42
					?>
43
					<div class="single-blog-post">
44
						<?php
45
							if ( ( function_exists( 'get_post_format' ) && 'image' == get_post_format( $post->ID ) )  ) {
46
															
47
							}elseif ( ( function_exists( 'get_post_format' ) && 'video' == get_post_format( $post->ID ) )  ) { 
48
								if(get_post_meta( $post->ID, "video_site", true ) == "youtube") {
49
									?>
50
									<iframe width="622" height="259" src="<?php echo get_post_meta( $post->ID, "video", true ); ?>" frameborder="0" allowfullscreen></iframe>
51
									<?php
52
								}elseif(get_post_meta( $post->ID, "video_site", true ) == "vimeo") {
53
									?>
54
									<iframe width="622" height="259" src="<?php echo get_post_meta( $post->ID, "video", true ); ?>" frameborder="0" allowfullscreen></iframe>
55
									<?php
56
								}else {
57
									?>
58
									<a href="<?php echo get_post_meta( $post->ID, "video", true ); ?>" style="display:block;width:622px;height:350px" class="fplayer" id="player-<?php echo $post->ID; ?>"></a>
59
									<script type="text/javascript">
60
										flowplayer("player-<?php echo $post->ID; ?>", "<?php echo get_template_directory_uri(); ?>/js/flowplayer/flowplayer-3.2.15.swf", { 
61
											clip:{ autoPlay:false,autoBuffering:false } 
62
										});
63
									</script>
64
									<?php
65
								}											
66
							}
67
						?>
68
						<?php
69
							if ( has_post_thumbnail() ) {
70
								?><span class="tail-large">&nbsp;</span><?php
71
							}
72
						?>
73
						<h4><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h4>
74
						<span class="details"><?php the_time('d F'); ?> on <?php the_category(', ') ?> &nbsp; <?php the_tags('Tags: ', ', ', ''); ?> </span>
75
						<?php the_content(); ?>
76
					</div>
77
					<?php
78
						endwhile; 					
79
					?>
80
				</div>
81

    
82
				<!--AUTHOR DETAILS-->
83
				<?php
84
					if(get_option('luna_hide_author_details') != "true") {
85
						?>
86
						<div class="author-details">
87
							<?php echo get_avatar( get_the_author_meta('email'), '50' ); ?>
88
							<label><span><?php _e( 'Author', 'luna_lang' ); ?></span> <?php the_author_meta('user_nicename'); ?></label>
89
							<p><?php the_author_meta('description'); ?></p>
90
							<ul>
91
								<li><a href="<?php the_author_meta('user_url'); ?>"><img src="<?php echo get_template_directory_uri(); ?>/img/icons/awebsite.png" alt="" title="" /></a></li>
92
								<li><a href="mailto:<?php the_author_meta('user_email'); ?>"><img src="<?php echo get_template_directory_uri(); ?>/img/icons/aemail.png" alt="" title="" /></a></li>
93
								<li><a href="http://twitter.com/<?php the_author_meta('twitter'); ?>"><img src="<?php echo get_template_directory_uri(); ?>/img/icons/atwitter.png" alt="" title="" /></a></li>
94
								<li><a href="http://facebook.com/<?php the_author_meta('facebook'); ?>"><img src="<?php echo get_template_directory_uri(); ?>/img/icons/afacebook.png" alt="" title="" /></a></li>
95
							</ul>
96
						</div>
97
						<?php
98
					}
99
				?>
100
				
101
				<?php comments_template();	?>	
102

    
103
			</div>
104

    
105
			<?php
106
				if(get_option( 'luna_blog_sidebar_type' ) == "Right") { ?> <div class="sidebar"> <?php }
107
				elseif(get_option( 'luna_blog_sidebar_type' ) == "Left") { ?><div class="left sidebar"><?php }
108
				else { ?> <div class="sidebar"> <?php }
109
				if($sidebar_choice == "Default") {
110
					get_sidebar( 'blog' );
111
				}else {
112
					get_custom_sidebar(); 
113
				}
114
			?>
115
			</div>
116

    
117
		</div>
118

    
119
	</div>
120
	
121

    
122
<?php get_footer(); ?>
(2-2/2)