<?php
/*
Plugin Name: Pubzi Core
Plugin URI: https://ex-coders.com/wp/pubzi/
Description: Plugin to contain short codes and custom post types of the Pubzi theme.
Author: pixel-plus
Author URI: https://themeforest.net/user/pixel-plus/portfolio
Version: 1.0.0
Text Domain: pubzi-core
*/


/**
 * If this file is called directly, abort.
 * @package pubzi
 * @since 1.0.0
 */
if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}


/**
 * Plugin directory path
 * @package pubzi
 * @since 1.0.0
 */
define( 'PUBZI_CORE_ROOT_PATH', plugin_dir_path( __FILE__ ) );
define( 'PUBZI_CORE_ROOT_URL', plugin_dir_url( __FILE__ ) );
define( 'PUBZI_CORE_SELF_PATH', 'pubzi-core/pubzi-core.php' );
define( 'PUBZI_CORE_VERSION', '1.0.0' );
define( 'PUBZI_CORE_INC', PUBZI_CORE_ROOT_PATH .'/inc');
define( 'PUBZI_CORE_LIB', PUBZI_CORE_ROOT_PATH .'/lib');
define( 'PUBZI_CORE_ELEMENTOR', PUBZI_CORE_ROOT_PATH .'/elementor');
define( 'PUBZI_CORE_DEMO_IMPORT', PUBZI_CORE_ROOT_PATH .'/demo-import');
define( 'PUBZI_CORE_ADMIN', PUBZI_CORE_ROOT_PATH .'/admin');
define( 'PUBZI_CORE_ADMIN_ASSETS', PUBZI_CORE_ROOT_URL .'admin/assets');
define( 'PUBZI_CORE_WP_WIDGETS', PUBZI_CORE_ROOT_PATH .'/wp-widgets');
define( 'PUBZI_CORE_ASSETS', PUBZI_CORE_ROOT_URL .'assets/');
define( 'PUBZI_CORE_CSS', PUBZI_CORE_ASSETS .'css');
define( 'PUBZI_CORE_JS', PUBZI_CORE_ASSETS .'js');
define( 'PUBZI_CORE_IMG', PUBZI_CORE_ASSETS .'img');


/**
 * Load additional helpers functions
 * @package pubzi
 * @since 1.0.0
 */
if (!function_exists('pubzi_core')){
	require_once PUBZI_CORE_INC .'/theme-core-helper-functions.php';
	if (!function_exists('pubzi_core')){
		function pubzi_core(){
			return class_exists('Pubzi_Core_Helper_Functions') ? new Pubzi_Core_Helper_Functions() : false;
		}
	}
}
//ob flash
remove_action( 'shutdown', 'wp_ob_end_flush_all', 1 );


/**
 * Load Codestar Framework Functions
 * @package pubzi
 * @since 1.0.0
 */
if ( !pubzi_core()->is_pubzi_active()) {
	if ( file_exists( PUBZI_CORE_ROOT_PATH . '/inc/csf-functions.php' ) ) {
		require_once PUBZI_CORE_ROOT_PATH . '/inc/csf-functions.php';
	}
}



/**
 * Core Plugin Init
 * @package pubzi
 * @since 1.0.0
 */
if ( file_exists( PUBZI_CORE_ROOT_PATH . '/inc/theme-core-init.php' ) ) {
	require_once PUBZI_CORE_ROOT_PATH . '/inc/theme-core-init.php';
}