// if (!class_exists('GavernWP')) { // include the framework base class require gavern_file('gavern/base.php'); } // load and parse template JSON file. $config_language = 'en_US'; if (get_locale() != '' && is_dir(get_template_directory() . '/gavern/config/' . get_locale()) && is_dir(get_template_directory() . '/gavern/options/' . get_locale())) { $config_language = get_locale(); } $json_data = json_decode(file_get_contents(get_template_directory() . '/gavern/config/' . $config_language . '/template.json')); $tpl_name = strtolower(preg_replace("/[^A-Za-z0-9]/", "", $json_data->template->name)); // define constant to use with all __(), _e(), _n(), _x() and _xe() usage define('GKTPLNAME', $tpl_name); // create the framework object $tpl = new GavernWP(); // Including file with helper functions require_once gavern_file('gavern/helpers/helpers.base.php'); // Including file with template hooks require_once gavern_file('gavern/hooks.php'); // Including file with template functions require_once gavern_file('gavern/functions.php'); require_once gavern_file('gavern/user.functions.php'); // Including file with template filters require_once gavern_file('gavern/filters.php'); // Including file with template widgets require_once gavern_file('gavern/widgets.comments.php'); require_once gavern_file('gavern/widgets.nsp.php'); require_once gavern_file('gavern/widgets.social.php'); require_once gavern_file('gavern/widgets.tabs.php'); // Including file with template admin features
// if (!class_exists('GavernWP')) { // include the framework base class require gavern_file('gavern/base.php'); } // load and parse template JSON file. $config_language = 'en_US'; if (get_locale() != '' && is_dir(get_template_directory() . '/gavern/config/' . get_locale()) && is_dir(get_template_directory() . '/gavern/options/' . get_locale())) { $config_language = get_locale(); } $json_data = json_decode(file_get_contents(get_template_directory() . '/gavern/config/' . $config_language . '/template.json')); $gk_tpl_name = strtolower(preg_replace("/[^A-Za-z0-9]/", "", $json_data->template->name)); // define constant to use with all __(), _e(), _n(), _x() and _xe() usage define('GKTPLNAME', $gk_tpl_name); // create the framework object $gk_tpl = new GavernWP(); // Including file with helper functions require_once gavern_file('gavern/helpers/helpers.base.php'); // Including file with template hooks require_once gavern_file('gavern/hooks.php'); // Including file with template functions require_once gavern_file('gavern/functions.php'); require_once gavern_file('gavern/user.functions.php'); // Including file with woocommerce functions if (isset($woocommerce)) { require_once gavern_file('gavern/wc-functions.php'); } // Including file with template filters require_once gavern_file('gavern/filters.php'); // Including file with template widgets require_once gavern_file('gavern/widgets.comments.php');