<?php /* Template Name: OnePage */
get_header('onepage'); 

$meta = _WSH()->get_meta();
$theme_options = _WSH()->option(); //printr($theme_options);
$single_pages = sh_set( $theme_options, 'single_pages' );
$single_pages = sh_set( $meta, 'single_pages' ) ? sh_set( $meta, 'single_pages' ) : $single_pages;
if( $single_pages ):?>

<?php $count = 1;
foreach((array) $single_pages as $page_id):
                ?>

    <section <?php echo 'id="section'.$page_id.'"' ; ?>>

		<?php 
        $page_data = get_page($page_id);
        echo apply_filters('the_content' , sh_set($page_data , 'post_content')) ; 
        ?>

	</section>

<?php  $count++;
endforeach; 

endif;?>
<?php get_footer(); ?>