<?php
/* =============================================================================
   USER ACTIONS
   ========================================================================== */
// CHECK THE PAGE IS NOT BEING LOADED DIRECTLY
if (!defined('THEME_VERSION')) {	header('HTTP/1.0 403 Forbidden'); exit; }

// SETUP GLOBALS
global $wpdb, $CORE, $settings;


wp_enqueue_script( 'jquery-ui-sortable' );
wp_enqueue_script( 'jquery-ui-draggable' );
wp_enqueue_script( 'jquery-ui-droppable' );


if( current_user_can('administrator') ){

	 // DO CONTENT
	
} 
 
_ppt_template('framework/admin/header' ); 
_ppt_template('framework/admin/_form-top' );

?>
<div class="tab-content">

 

<?php if(_ppt(array('links','countries')) == ""){ ?>

   <div class="alert alert-warning p-3 border-warning fs-14"><i class="fa fa-exclamation-triangle mr-2"></i> <?php echo __("No country list page found.","premiumpress"); ?> <a href="admin.php?page=settings&lefttab=pagelinks"><?php echo __("Setup one now.","premiumpress"); ?></a> </div>

<?php } ?> 
      
       
	<div class="tab-pane addjumplink active" 
        data-title="<?php echo __("Locations","premiumpress"); ?>" 
        data-desc=""
        data-icon="fa-search" 
        id="overview" 
        role="tabpanel" aria-labelledby="overview-tab">
    	<?php _ppt_template('framework/admin/parts/locations-overview' ); ?>     
        </div> 
        
        <?php /*
        <div class="tab-pane addjumplink" 
        data-title="<?php echo __("Live Data","premiumpress"); ?>" 
        data-desc="<?php echo __("Here you view all live data.","premiumpress"); ?>"
        data-icon="fa-map-marker" 
        id="v" 
        role="tabpanel" aria-labelledby="v-tab">
  		<?php _ppt_template('framework/admin/parts/locations-view' ); ?> 
        </div> 
        */ ?>
 
        
	<div class="tab-pane addjumplink" 
        data-title="<?php echo __("Import Country/City Data","premiumpress"); ?>" 
        data-desc="<?php echo __("Here you can manage country and city data.","premiumpress"); ?>"
        data-icon="fa-file" 
        id="c" 
        role="tabpanel" aria-labelledby="c-tab">
  		<?php _ppt_template('framework/admin/parts/locations-data' ); ?> 
        </div>  

        <div class="tab-pane addjumplink" 
        data-title="<?php echo __("Settings","premiumpress"); ?>" 
        data-desc="<?php echo __("Additional website settings.","premiumpress"); ?>"
        data-icon="fa-cog" 
        id="h" 
        role="tabpanel" aria-labelledby="h-tab">
  		<?php _ppt_template('framework/admin/parts/locations-settings' ); ?> 
        </div>  
        
        
      <?php /* if(isset($_GET['adminonly'])){ ?>
         
  <div class="tab-pane addjumplink" 
        data-title="<?php echo __("Search Analytics","premiumpress"); ?>" 
        data-desc=""
        data-icon="fa-chart-line" 
        id="a" 
        role="tabpanel" aria-labelledby="a-tab">
		 <?php _ppt_template('framework/admin/parts/search-analytics' ); ?>  
        </div> 
        
       
  <div class="tab-pane addjumplink" 
        data-title="<?php echo __("IP Targeting","premiumpress"); ?>" 
        data-desc="<?php echo __("Detect the user IP addresses to display localized content.","premiumpress")."<br><br><br><span class='badge badge-success'>Beta Test</span> This section is currently under beta testing. More options to come in future updates."; ?>"
        data-icon="fa-map-marker" 
        id="ip" 
        role="tabpanel" aria-labelledby="ip-tab">
		 <?php _ppt_template('framework/admin/parts/locations-ip' ); ?>  
        </div> 
      <?php } ?> 

      <?php /*




*/ ?>
 
</div> 
  
<?php 
_ppt_template('framework/admin/_form-bottom' ); 
_ppt_template('framework/admin/footer' );
?>