<?php
/**
 * Page view
 *
 * @package wp-viral-click
 * @author InstaProduct
 * @link http://insta-product.com/
 */

$this->view( 'front/page/header' );

$class = get_post_meta( $this->page->ID, '__ipjck-page-class', true );
if ( $this->setting->getSetting( 'link_replace_active', 'false' ) == 'true' ) {
    $replace = 1;
} else {
    $replace = 0;
}
?>
<body class="ipjck-site">
  <div class="ipjck-root">
    <div class="ipjck-pre-content">
    	<?php
    	if ( $this->setting->getSetting( 'prepend_html' ) ) {
    		echo $this->setting->getSetting( 'prepend_html' );
    	}
    	?>
    </div>
    <div class="ipjck-content <?php echo $class; ?>" data-replace-link="<?php echo $replace; ?>" data-page-id="<?php echo $this->page->ID; ?>">

        <?php
        $content = get_post_meta( $this->page->ID, '__ipjck-page-body', true );
        if ( ! empty( $content )) {
        	echo $content;
        }
        ?>

    </div>
    <div class="ipjck-post-content">
    	<?php
    	if ( $this->setting->getSetting( 'append_html' ) ) {
    		echo $this->setting->getSetting( 'append_html' );
    	}
    	?>
    </div>

  <div class="ipjck-widgets">
	  <?php 
	  $this->view( 'front/page/bar' );
	  $this->view( 'front/page/modal' );
	  $this->view( 'front/page/slidein' );
	  ?>
  </div>
  
  </div>
<?php 
$this->view( 'front/page/footer' );
?>
