/** * Return a single instance of this class * * @return object */ public static function instance() { if (!isset(self::$instance) && !self::$instance instanceof OIK_libs) { self::$instance = new OIK_libs(); } return self::$instance; }
/** * Return the singular instance of the OIK_libs class * * @return object the OIK_libs class */ function oik_libs() { if (!class_exists("OIK_libs")) { oik_require("includes/class-oik-libs.php", "oik-lib"); oik_require("includes/class-oik-lib.php", "oik-lib"); } if (class_exists("OIK_libs")) { $oik_libs = OIK_libs::instance(); } else { die; } return $oik_libs; }