<?php

/*

 *

 Template Name: Portfolio Two Column B

 * 

 * This template is used to display the two-column portfolio page. 

 *

 */ 

 get_header(); ?>



<?php if ( has_post_thumbnail()) { ?>

	<div class="row">

		<div id="banner"><?php the_post_thumbnail( 'banner' ); ?></div>

	</div>

<?php } else { } ?>



<!-- #content -->

<div id="content">

	

	<!-- .row -->

	<div class="row portfolio">



		<!-- BEGIN .hentry 'cat'=>'4',-->

		<div <?php post_class(); ?> id="page-<?php the_ID(); ?>">

	    

	    	<h1 class="headline alt">on going projects</h1>

	        

			<?php $first_or_second = 'first'; ?>  

			<?php $wp_query = new WP_Query(array('cat'=>'7','showposts'=>of_get_option('postnumber_portfolio_two'),'paged'=>$paged)); ?>

			<?php if($wp_query->have_posts()) : while($wp_query->have_posts()) : $wp_query->the_post(); ?>

			<?php $meta_box = get_post_custom($post->ID); $video = $meta_box['custom_meta_video'][0]; ?>

			<?php global $more; $more = 0; ?>

	        

			<!-- BEGIN .six columns -->

			<div class="six columns <?php echo $first_or_second; ?>">

			<?php $first_or_second = ('first'==$first_or_second) ? 'second' : 'first'; ?> 

		

				<!-- BEGIN .portfolio-item -->

				<div class="portfolio-item">

		

		    		<?php if ( $video ) : ?>

		        			<div class="feature_vid"><?php echo $video; ?></div>

		    		<?php else: ?>

		        			<div class="feature_img"><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_post_thumbnail( 'portfolio-medium' ); ?></a></div>

		    		<?php endif; ?>

		        

		        	<?php if(of_get_option('display_portfolio_page_info') == '1') { ?>

		        	    <div class="information">              

		        	        <h2 class="title"><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>

		        	        <?php the_excerpt(); ?>

		        	    </div><!-- information -->

		        	<?php } else { ?>

		        	<?php } ?>

		        

				<!-- END .portfolio-item -->

		        </div>

		

			<!-- END .six columns -->

			</div>

		                            

			<?php endwhile; ?>

		

			<div class="pagination">

				<?php if (function_exists("number_paginate")) { number_paginate(); } ?>

			</div>

		

			<?php else : // do not delete ?>

		

			<div class="twelve columns">

			

				<div class="article">

					<h1 class="headline"><?php _e("No Posts Found", 'organicthemes'); ?></h1>

					<p><?php _e("We're sorry, but no posts were found for this category.", 'organicthemes'); ?></p>

					<p><?php _e("Try searching for the page you are looking for or using the navigation in the header or sidebar.", 'organicthemes'); ?></p>

				</div>

				

			</div><!-- .twelve columns -->

		

		    <?php endif; // do not delete ?>

	

		<!-- END .hentry -->

		</div>

</div>	

	<div class="row portfolio">



		<!-- BEGIN .hentry 'cat'=>'4',-->

		<div <?php post_class(); ?> id="page-<?php the_ID(); ?>">

	    

	    	<h1 class="headline alt">future projects</h1>

	        

			<?php $first_or_second = 'first'; ?>  

			<?php $wp_query = new WP_Query(array('cat'=>'8','showposts'=>of_get_option('postnumber_portfolio_two'),'paged'=>$paged)); ?>

			<?php if($wp_query->have_posts()) : while($wp_query->have_posts()) : $wp_query->the_post(); ?>

			<?php $meta_box = get_post_custom($post->ID); $video = $meta_box['custom_meta_video'][0]; ?>

			<?php global $more; $more = 0; ?>

	        

			<!-- BEGIN .six columns -->

			<div class="six columns <?php echo $first_or_second; ?>">

			<?php $first_or_second = ('first'==$first_or_second) ? 'second' : 'first'; ?> 

		

				<!-- BEGIN .portfolio-item -->

				<div class="portfolio-item">

		

		    		<?php if ( $video ) : ?>

		        			<div class="feature_vid"><?php echo $video; ?></div>

		    		<?php else: ?>

		        			<div class="feature_img"><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_post_thumbnail( 'portfolio-medium' ); ?></a></div>

		    		<?php endif; ?>

		        

		        	<?php if(of_get_option('display_portfolio_page_info') == '1') { ?>

		        	    <div class="information">              

		        	        <h2 class="title"><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>

		        	        <?php the_excerpt(); ?>

		        	    </div><!-- information -->

		        	<?php } else { ?>

		        	<?php } ?>

		        

				<!-- END .portfolio-item -->

		        </div>

		

			<!-- END .six columns -->

			</div>

		                            

			<?php endwhile; ?>

		

			<div class="pagination">

				<?php if (function_exists("number_paginate")) { number_paginate(); } ?>

			</div>

		

			<?php else : // do not delete ?>

		

			<div class="twelve columns">

			

				<div class="article">

					<h1 class="headline"><?php _e("No Posts Found", 'organicthemes'); ?></h1>

					<p><?php _e("We're sorry, but no posts were found for this category.", 'organicthemes'); ?></p>

					<p><?php _e("Try searching for the page you are looking for or using the navigation in the header or sidebar.", 'organicthemes'); ?></p>

				</div>

				

			</div><!-- .twelve columns -->

		

		    <?php endif; // do not delete ?>

	

		<!-- END .hentry -->

		</div>

<div class="row portfolio">



		<!-- BEGIN .hentry 'cat'=>'4',-->

		<div <?php post_class(); ?> id="page-<?php the_ID(); ?>">

	    

	    	<h1 class="headline alt">ended projects</h1>

	        

			<?php $first_or_second = 'first'; ?>  

			<?php $wp_query = new WP_Query(array('cat'=>'6','showposts'=>of_get_option('postnumber_portfolio_two'),'paged'=>$paged)); ?>

			<?php if($wp_query->have_posts()) : while($wp_query->have_posts()) : $wp_query->the_post(); ?>

			<?php $meta_box = get_post_custom($post->ID); $video = $meta_box['custom_meta_video'][0]; ?>

			<?php global $more; $more = 0; ?>

	        

			<!-- BEGIN .six columns -->

			<div class="six columns <?php echo $first_or_second; ?>">

			<?php $first_or_second = ('first'==$first_or_second) ? 'second' : 'first'; ?> 

		

				<!-- BEGIN .portfolio-item -->

				<div class="portfolio-item">

		

		    		<?php if ( $video ) : ?>

		        			<div class="feature_vid"><?php echo $video; ?></div>

		    		<?php else: ?>

		        			<div class="feature_img"><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_post_thumbnail( 'portfolio-medium' ); ?></a></div>

		    		<?php endif; ?>

		        

		        	<?php if(of_get_option('display_portfolio_page_info') == '1') { ?>

		        	    <div class="information">              

		        	        <h2 class="title"><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>

		        	        <?php the_excerpt(); ?>

		        	    </div><!-- information -->

		        	<?php } else { ?>

		        	<?php } ?>

		        

				<!-- END .portfolio-item -->

		        </div>

		

			<!-- END .six columns -->

			</div>

		                            

			<?php endwhile; ?>

		

			<div class="pagination">

				<?php if (function_exists("number_paginate")) { number_paginate(); } ?>

			</div>

		

			<?php else : // do not delete ?>

		

			<div class="twelve columns">

			

				<div class="article">

					<h1 class="headline"><?php _e("No Posts Found", 'organicthemes'); ?></h1>

					<p><?php _e("We're sorry, but no posts were found for this category.", 'organicthemes'); ?></p>

					<p><?php _e("Try searching for the page you are looking for or using the navigation in the header or sidebar.", 'organicthemes'); ?></p>

				</div>

				

			</div><!-- .twelve columns -->

		

		    <?php endif; // do not delete ?>

	

		<!-- END .hentry -->

		</div>



	<!-- .row -->

	</div>



<!-- #content -->	

</div>



<?php get_footer(); ?>