/**
  * Provides access to a single instance of a module using the singleton pattern
  *
  * @since    1.0.0
  * @return object
  */
 public static function get_instance()
 {
     if (null === self::$instance) {
         self::$instance = new self();
     }
     return self::$instance;
 }
 /**
  * Run the loader to execute all of the hooks with WordPress.
  *
  * @since    1.0.0
  */
 public function run()
 {
     if (isset($_POST['download'])) {
         $this->generateExport();
     } else {
         $this->loader->run();
     }
 }
 /**
  * Run the loader to execute all of the hooks with WordPress.
  *
  * @since    1.0.0
  */
 public function run()
 {
     $this->loader->run();
 }
Example #4
0
 /**
  * Run the loader to execute all of the hooks with WordPress.
  *
  * @since    1.0.0
  */
 public function run()
 {
     $this->loader->run();
     //[foobar]
 }
 /**
  * Define the core functionality of the plugin.
  *
  * Load the dependencies, define the locale, and set the hooks for the admin area and
  * the public-facing side of the site.
  *
  * @since    1.0.0
  */
 public function __construct()
 {
     self::$plugin_path = plugin_dir_path(dirname(__FILE__));
     self::$plugin_url = plugin_dir_url(dirname(__FILE__));
     require_once self::$plugin_path . 'includes/class-' . self::PLUGIN_PREFIX . 'loader.php';
     self::$modules['Plugin_Name_Loader'] = Plugin_Name_Loader::get_instance();
     self::$modules['Plugin_Name_Controller_Public'] = Plugin_Name_Controller_Public::get_instance();
     self::$modules['Plugin_Name_Controller_Admin_Settings'] = Plugin_Name_Controller_Admin_Settings::get_instance();
     self::$modules['Plugin_Name_Controller_Admin_Notices'] = Plugin_Name_Controller_Admin_Notices::get_instance();
     Plugin_Name_Actions_Filters::init_actions_filters();
 }
function uninstall_plugin_name_plugin()
{
    require_once plugin_dir_path(__FILE__) . 'includes/class-plugin-name-loader.php';
    Plugin_Name_Loader::uninstall_plugin();
}