static $version = '0.1.0'; public static function init() { if (null == self::$app) { self::$app = new Plugin_Name\App(); self::$app->run(); } return self::$app; } } /** * Begins execution of the plugin. * * Since everything within the plugin is registered via hooks, * then kicking off the plugin from this point in the file does * not affect the page life cycle. * * Also returns copy of the app object so 3rd party developers * can interact with the plugin's hooks contained within. * * @return Plugin_Name\App App Plugin's app object * @since 1.0.0 */ function plugin_name() { return Plugin_Name::init(); } $updatePhp = new WPUpdatePhp('5.3.0'); if ($updatePhp->does_it_meet_required_php_version(PHP_VERSION)) { plugin_name(); }
/** * Function to initialize plugin */ function plugin_name_init() { plugin_name()->run(); }
<table class="table"> <thead> <tr> <td>Eklenti Bilgileri</td> </tr> </thead> <tbody> <?php foreach (get_plugins() as $plugin) { set_plugin_data($plugin); ?> <tr> <td> <span class="name"> <?php echo plugin_name(); ?> - adlı eklenti şu anda : <?php echo is_active_plugin() ? '<font color="green">aktif</font>' : '<font color="red">pasif</font>'; ?> </span> <span class="author"><?php echo plugin_author(); ?> </span> <span class="description"><?php echo plugin_description(); ?> </span> <span class="url"> <a target="_blank" href="<?php