| 1 |
<?php |
| 2 |
/* |
| 3 |
Plugin Name: Tutor LMS |
| 4 |
Plugin URI: http://https://themeum.com/tutor |
| 5 |
Description: Tutor is a complete solution for creating a Learning Management System in WordPress way. It can help you to create small to large scale online education site very conveniently. Power features like report, certificate, course preview, private file sharing make Tutor a robust plugin for any educational institutes. |
| 6 |
Author: Themeum |
| 7 |
Version: 1.0.7 |
| 8 |
Author URI: http://themeum.com |
| 9 |
Requires at least: 4.5 |
| 10 |
Tested up to: 5.1 |
| 11 |
Text Domain: tutor |
| 12 |
Domain Path: /languages/ |
| 13 |
*/ |
| 14 |
if ( ! defined( 'ABSPATH' ) ) |
| 15 |
exit; |
| 16 |
|
| 17 |
/** |
| 18 |
* Defined the tutor main file |
| 19 |
*/ |
| 20 |
define('TUTOR_VERSION', '1.0.7'); |
| 21 |
define('TUTOR_FILE', __FILE__); |
| 22 |
|
| 23 |
|
| 24 |
/** |
| 25 |
* Load tutor text domain for translation |
| 26 |
*/ |
| 27 |
add_action( 'init', 'tutor_language_load' ); |
| 28 |
function tutor_language_load(){ |
| 29 |
load_plugin_textdomain( 'tutor', false, basename( dirname( __FILE__ ) ) . '/languages' ); |
| 30 |
} |
| 31 |
|
| 32 |
/** |
| 33 |
* Tutor Helper function |
| 34 |
* |
| 35 |
* @since v.1.0.0 |
| 36 |
*/ |
| 37 |
|
| 38 |
if ( ! function_exists('tutor')) { |
| 39 |
function tutor() { |
| 40 |
$path = plugin_dir_path( TUTOR_FILE ); |
| 41 |
$hasPro = defined('TUTOR_PRO_VERSION'); |
| 42 |
|
| 43 |
$info = array( |
| 44 |
'path' => $path, |
| 45 |
'url' => plugin_dir_url( TUTOR_FILE ), |
| 46 |
'basename' => plugin_basename( TUTOR_FILE ), |
| 47 |
'version' => TUTOR_VERSION, |
| 48 |
'nonce_action' => 'tutor_nonce_action', |
| 49 |
'nonce' => '_wpnonce', |
| 50 |
'course_post_type' => apply_filters( 'tutor_course_post_type', 'course' ), |
| 51 |
'lesson_post_type' => apply_filters( 'tutor_lesson_post_type', 'lesson' ), |
| 52 |
'instructor_role' => apply_filters( 'tutor_instructor_role', 'tutor_instructor' ), |
| 53 |
'instructor_role_name' => apply_filters( 'tutor_instructor_role_name', __( 'Tutor Instructor', 'tutor' ) ), |
| 54 |
'template_path' => apply_filters( 'tutor_template_path', 'tutor/' ), |
| 55 |
'has_pro' => $hasPro, |
| 56 |
); |
| 57 |
|
| 58 |
return (object) $info; |
| 59 |
} |
| 60 |
} |
| 61 |
include 'classes/init.php'; |
| 62 |
|
| 63 |
function tutor_utils(){ |
| 64 |
return new \TUTOR\Utils(); |
| 65 |
} |
| 66 |
|
| 67 |
$tutor = new \TUTOR\init(); |
| 68 |
$tutor->run(); //Boom |