<?php
    $GLOBALS['img']='single';
    get_header();
?>

<div id="primary" class="content-area">

    <div class="container">
    
        <div class="row-fluid top">
     
            <?php
        if(of_get_option('single_layer_img') == 'right'){
            $span8 = 'span8';
            $pos = 'right';  
        }else if(of_get_option('single_layer_img') == 'left'){
            $span8 = 'span8';
            $pos = 'left';
        }else{
            $span8 = 'span12';
            $pos = 'none';
        }                    
        if($pos == 'left'){echo '<div class="span4">'; get_sidebar(); echo '</div>';}
    ?>
     
            <div class="<?php echo $span8;?>">
                
				<!-- blog  -->
				
                <div class="blog">
		  
                    <div class="row-fluid">
			
                        <div class="span12">
			  
                            <!-- post  -->
				
                            <div class="post">
				
                                <?php 
							        the_post();
                                    $day = get_the_time('j');
                                    $month = get_the_time('M');
                                    $year = get_the_time('Y');
                                ?>
				  
                                <!-- Image Post -->
				  
                                <div class="post_img">
				  
                                    <a <?php echo colors('a');?>  href="<?php the_permalink();?>">
								
                                        <?php
                                            if( has_post_thumbnail($post->ID) ) { the_post_thumbnail('full', array('alt'=>$post->post_title)); }
                                            else { echo '<img src="' . get_template_directory_uri('template_directory') . '/img/default.jpg" />'; }
                                        ?>
                                    </a>
					
                                    <div class="post_hover">
					
                                        <h3 <?php echo colors('h3');?> ><?php the_title();?></h3> 
					  
                                    </div>
					
                                </div>
				  
                                <!-- Image Post -->
				  
                                <ul>
								
                                    <li><a <?php echo colors('a');?>  href="<?php the_permalink();?>"><i class="icon-group"></i> <?php the_author();?></a></li>
                                    <li><a <?php echo colors('a');?>  href="<?php the_permalink();?>"><i class="icon-tag"></i><?php echo $day.'/'.$month.'/'.$year;?></a></li>
                                    <li><a <?php echo colors('a');?>  href="<?php the_permalink();?>"><i class="icon-quote-left"></i><?php comments_number();?></a></li>
									
                                </ul>
								
								<div class="single_page">
								
                                    <?php insert_br(the_content());?>
							   
							        <?php wp_link_pages( array( 'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'newhost' ) . '</span>', 'after' => '</div>', 'link_before' => '<span>', 'link_after' => '</span>' ) ); ?>
							    
								</div>
							   
                            </div>
				
				            <?php comments_template(); ?><!-- end Comments -->
				
                            <!-- end post -->
							
                        </div>
						
                    </div>
					
                </div>
				
                <!-- end blog  -->  
            </div>
	  
	        <?php if($pos == 'right'){echo '<div class="span4">'; get_sidebar(); echo '</div>';} ?>
      
        </div>
   
        <!-- End Container -->
   
    </div>
	
    </div>
	
</div>
	
<?php get_footer(); ?>