/** * Plugin Loader init * @static * @since 1.0 */ public static function init() { self::check_for_upgrade(); self::$settings = get_option('WCSSC_options') ? get_option('WCSSC_options') : array(); self::include_files(); self::call_wp_hooks(); new WCSSC_Settings(); }
/** * Define constants and load the plugin * @since 1.0 */ function widget_css_classes_loader() { $languages_path = plugin_basename(dirname(__FILE__) . '/languages'); load_plugin_textdomain('widget-css-classes', '', $languages_path); if (is_admin()) { if (!defined('WCSSC_PLUGIN_VERSION')) { define('WCSSC_PLUGIN_VERSION', '1.2'); } if (!defined('WCSSC_FILE')) { define('WCSSC_FILE', __FILE__); } if (!defined('WCSSC_BASENAME')) { define('WCSSC_BASENAME', plugin_basename(__FILE__)); } if (!defined('WCSSC_PLUGIN_DIR')) { define('WCSSC_PLUGIN_DIR', plugin_dir_path(__FILE__)); } if (!defined('WCSSC_PLUGIN_URL')) { define('WCSSC_PLUGIN_URL', plugins_url('', __FILE__)); } include_once 'includes/widget-css-classes-loader.class.php'; WCSSC_Loader::init(); } }