-
Notifications
You must be signed in to change notification settings - Fork 17
/
tutor-lms-divi-modules.php
67 lines (59 loc) · 1.85 KB
/
tutor-lms-divi-modules.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
/*
Plugin Name: Tutor LMS Divi Modules
Description: Easily design your courses and lessons on Divi builder with Tutor LMS
Version: 2.0.1
Author: Themeum
Author URI: https://themeum.com
Requires at least: 5.3
Tested up to: 6.0
License: GPLv3
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Text Domain: tutor-lms-divi-modules
Domain Path: /languages
*/
defined( 'ABSPATH' ) || die();
define( 'DTLMS_VERSION', '2.0.1' );
define( 'DTLMS_FILE__', __FILE__ );
define( 'DTLMS_DIR_PATH', plugin_dir_path( DTLMS_FILE__ ) );
define( 'DTLMS_DIR_URL', plugin_dir_url( DTLMS_FILE__ ) );
define( 'DTLMS_ASSETS', trailingslashit( DTLMS_DIR_URL . 'assets' ) );
define( 'DTLMS_TEMPLATES', trailingslashit( DTLMS_DIR_PATH . 'includes/templates/course/' ) );
/**
* Tutor LMS Divi Modules v2.0.0 dependency on Tutor core
*
* Define Tutor core version on that Tutor LMS Divi Modules is dependent to run,
* without require version v2.0.0 will just show admin notice to install require core version.
*
* @since v2.0.0
*/
define( 'DTLMS_TUTOR_CORE_REQ_VERSION', '2.0.0' );
/**
* Environment
* PROD
* DEV
*/
define( 'DTLMS_ENV', 'PROD' );
if ( ! function_exists( 'tudm_initialize_extension' ) ) :
/**
* Creates the extension's main class instance.
*
* @since 1.0.0
*/
function tudm_initialize_extension() {
require_once plugin_dir_path( __FILE__ ) . 'includes/classes/Dependency.php';
require_once plugin_dir_path( __FILE__ ) . 'includes/TutorDiviModules.php';
}
/**
* Load plugin text domain
*
* @since 1.0.0
*/
add_action( 'init', 'tutor_divi_textdomain' );
if ( ! function_exists( 'tutor_divi_textdomain' ) ) {
function tutor_divi_textdomain() {
load_plugin_textdomain( 'tutor-lms-divi-modules', false, dirname( plugin_basename( __FILE__ ) . '/languages' ) );
}
}
add_action( 'divi_extensions_init', 'tudm_initialize_extension' );
endif;