/** * Class constructor * * @since 1.0.0 * @internal */ public function __construct() { parent::__construct(); self::$core = $this; // A List of all components. $components = array('array', 'debug', 'html', 'net', 'session', 'updates', 'ui'); // Create instances of each component. foreach ($components as $component) { if (!property_exists($this, $component)) { continue; } $class_name = str_replace('Core', ucfirst($component), __CLASS__); $this->{$component} = new $class_name(); } }
/** * Class constructor * * @since 1.0.0 * @internal */ public function __construct() { parent::__construct(); // Check for persistent data from last request that needs to be processed. $this->add_action('plugins_loaded', '_check_admin_notices'); }
/** * Session storage * * @since 1.1.0 * @internal */ private static function _sess_init() { if (null !== self::$_have_session) { return; } self::$_have_session = false; if (!session_id()) { if (!headers_sent()) { session_start(); self::$_have_session = true; } } else { self::$_have_session = true; } }
/** * Class constructor * * @since 1.1.0 */ public function __construct() { parent::__construct(); }