<?php
/* 
* Theme: PREMIUMPRESS CORE FRAMEWORK FILE
* Url: www.premiumpress.com
* Author: Mark Fail
*
* THIS FILE WILL BE UPDATED WITH EVERY UPDATE
* IF YOU WANT TO MODIFY THIS FILE, CREATE A CHILD THEME
*
* http://codex.wordpress.org/Child_Themes
*/
if (!defined('THEME_VERSION')) {	header('HTTP/1.0 403 Forbidden'); exit; }

global $post, $CORE_UI, $userdata, $CORE;

   // ADMIN PREVIEW
    if(!isset($post->ID)){
		$post = new stdClass();
		$post->ID 			= 1;
		$post->post_title 	= "This is a sample title."; 
		$post->post_author 	= 1; 
		$post->post_excerpt = "";
		$post->post_content = "";
		$post->comment_count = 0;
		$post->thistheme = THEME_KEY;
		
		$post->showupgrades = 1;
	}
	
	if($post->thistheme == "jb"){
 	    
        $logoimg = do_shortcode("[COMPANYLOGO pid='".$post->ID."']");
        if(strlen($logoimg) > 1){
        $post->image = $logoimg;
        }
	}
 
?>
 
<div ppt-box class="hide-mobile rounded mb-4 p-3" data-pid='%postid%' <?php if(isset($post->carddata)){ echo $post->carddata; } ?>>  

  <div class="d-sm-flex">
    <div style="min-width:150px;" class="mobile-mb-2">
      <a href="%link%">
      <div class="p-2 <?php if($post->thistheme == "jb"){ ?>bg-white<?php }else{ ?>bg-light<?php } ?>" ppt-border1>
        <div class="bg-light position-relative overflow-hidden <?php if($post->thistheme == "jb"){ ?>bg-image-centered<?php } ?>" style="height:120px;">
          <div class="bg-image bg-white" data-ppt-image-bg>
            &nbsp;
          </div>
        </div>
      </div>
      </a>
    </div>
    <div class="position-relative w-100 pl-lg-4">
      <div class="d-sm-flex flex-sm-column">
        <div class="fs-4 text-600 mb-2">
          <a href="%link%" class="text-dark _adtitle">%title%</a>
        </div>
        <div style="min-height:60px;">
          <?php echo do_shortcode("[EXCERPT limit=150]"); ?>...
        </div> 
         
        <nav ppt-nav class="seperator pl-0 text-muted">
          
        <ul> 
        <li class="<?php echo $CORE->GEO("price_formatting",array()); ?>">%price%</li>  
        <li>%SALARYTYPE%</li> 
        <li>%JOBTYPE%</li> 
        <li class="ml-auto">%city%</li>

        <?php  if(isset($post->distance) && $post->distance > 0 ){  ?>
          <li><?php  echo $post->distance_text; ?> </li>
          <?php } ?>


        </ul>
    </nav>
      </div>
    </div>
  </div>
</div>

<?php _ppt_template( 'cards/jb/mobile' );  ?>
