-
Notifications
You must be signed in to change notification settings - Fork 1
/
bb-class-dropdown.php
56 lines (46 loc) · 1.79 KB
/
bb-class-dropdown.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
<?php
/**
* Beaver Builder Class Dropdown
*
* @package BBClassDropdown
* @author PYLE/DIGITAL
* @license GPL-3.0+
*
* @wordpress-plugin
* Plugin Name: Beaver Builder Class Dropdown
* Plugin URI: https://github.com/zackpyle/BBClassDropdown
* Description: BB Class Dropdown adds user defined CSS classes to dropdown below the Beaver Builder class input in the Advanced tab
* Version: 1.0.6
* Author: PYLE/DIGITAL
* Author URI: https://github.com/zackpyle
* Text Domain: BBClassDropdown
* License: GPL-3.0+
* License URI: https://www.gnu.org/licenses/gpl-3.0.txt
*/
use BBClassDropdown\Autoloader;
use BBClassDropdown\Init;
if ( defined( 'ABSPATH' ) && ! defined( 'BBCLASSDROPDOWN_VERION' ) ) {
register_activation_hook( __FILE__, 'BBCLASSDROPDOWN_check_php_version' );
/**
* Display notice for old PHP version.
*/
function BBCLASSDROPDOWN_check_php_version() {
if ( version_compare( phpversion(), '7.4', '<' ) ) {
die( esc_html__( 'BB Class Dropdown requires PHP version 7.4+. Please contact your host to upgrade.', 'BBClassDropdown' ) );
}
}
define( 'BBCLASSDROPDOWN_VERSION' , '1.0.5' );
define( 'BBCLASSDROPDOWN_DIR' , plugin_dir_path( __FILE__ ) );
define( 'BBCLASSDROPDOWN_BASE' , plugin_basename( __FILE__ ) );
define( 'BBCLASSDROPDOWN_FILE' , __FILE__ );
define( 'BBCLASSDROPDOWN_URL' , plugins_url( '/', __FILE__ ) );
define( 'CHECK_BBCLASSDROPDOWN_PLUGIN_FILE', __FILE__ );
}
if ( ! class_exists( 'BBClassDropdown\Init' ) ) {
/**
* The file where the Autoloader class is defined.
*/
require_once BBCLASSDROPDOWN_DIR . 'includes/classes/Autoloader.php';
spl_autoload_register( array( new Autoloader(), 'autoload' ) );
$plugin_var = new Init();
}