. */ // If this file is called directly, abort. defined( 'WPINC' ) || die( 'Well, get lost.' ); // Make sure loggedin is not already defined. if ( ! function_exists( 'loggedin_init' ) ) { /** * Main instance of plugin. * * Returns the main instance of Beehive to prevent the need to use globals * and to maintain a single copy of the plugin object. * You can simply call beehive_analytics() to access the object. * * @since 1.3.0 * * @return void */ function loggedin_init() { // Load text domain. load_plugin_textdomain( 'loggedin', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' ); // Load required files. require dirname( __FILE__ ) . '/includes/class-loggedin.php'; require dirname( __FILE__ ) . '/includes/class-loggedin-admin.php'; // Load core class. new Loggedin(); // Load admin class. new Loggedin_Admin(); /** * Action hook to execute after LoggedIn plugin init. * * Use this hook to init addons. * * @since 1.3.1 */ do_action( 'loggedin_init' ); } } // Init the plugin. add_action( 'plugins_loaded', 'loggedin_init' );