| 1 |
<?php |
| 2 |
/** |
| 3 |
* The plugin bootstrap file |
| 4 |
* |
| 5 |
* @link http://nabillemsieh.com |
| 6 |
* @since 1.0.0 |
| 7 |
* @package Hurrytimer |
| 8 |
* |
| 9 |
* @wordpress-plugin |
| 10 |
* Plugin Name: HurryTimer |
| 11 |
* Plugin URI: https://wordpress.org/plugins/hurrytimer |
| 12 |
* Description: A Scarcity Countdown Timer for WordPress & WooCommerce |
| 13 |
* Version: 1.2.4 |
| 14 |
* Author: Nabil Lemsieh |
| 15 |
* Author URI: http://nabillemsieh.com |
| 16 |
* License: GPLv3 |
| 17 |
* License URI: http://www.gnu.org/licenses/gpl.html |
| 18 |
* Text Domain: hurrytimer |
| 19 |
* Domain Path: /languages |
| 20 |
*/ |
| 21 |
namespace Hurrytimer; |
| 22 |
|
| 23 |
// If this file is called directly, abort. |
| 24 |
if (!defined('WPINC')) { |
| 25 |
die; |
| 26 |
} |
| 27 |
|
| 28 |
define('HURRYTIMER_PLUGIN_VERSION', '1.2.4'); |
| 29 |
define('HURRYTIMER_DB_VERSION', '1.0.0'); |
| 30 |
define('HURRYTIMER_PLUGIN_NAME', 'hurrytimer'); |
| 31 |
define('HURRYTIMER_PLUGIN_DIR', plugin_dir_path(__FILE__)); |
| 32 |
define('HURRYTIMER_PLUGIN_URL', plugin_dir_url(__FILE__)); |
| 33 |
define('HURRYTIMER_COUNTDOWN_PT', 'hurrytimer_countdown'); |
| 34 |
|
| 35 |
function activate_hurrytimer() |
| 36 |
{ |
| 37 |
require_once plugin_dir_path(__FILE__) . 'includes/class-hurrytimer-activator.php'; |
| 38 |
Hurrytimer_Activator::activate(); |
| 39 |
} |
| 40 |
|
| 41 |
function deactivate_hurrytimer() |
| 42 |
{ |
| 43 |
require_once plugin_dir_path(__FILE__) . 'includes/class-hurrytimer-deactivator.php'; |
| 44 |
Hurrytimer_Deactivator::deactivate(); |
| 45 |
} |
| 46 |
|
| 47 |
register_activation_hook(__FILE__, 'Hurrytimer\activate_hurrytimer'); |
| 48 |
register_deactivation_hook(__FILE__, 'Hurrytimer\deactivate_hurrytimer'); |
| 49 |
|
| 50 |
/** |
| 51 |
* The core plugin class that is used to define internationalization, |
| 52 |
* admin-specific hooks, and public-facing site hooks. |
| 53 |
*/ |
| 54 |
require plugin_dir_path(__FILE__) . 'includes/class-hurrytimer.php'; |
| 55 |
|
| 56 |
/** |
| 57 |
* Begins execution of the plugin. |
| 58 |
* |
| 59 |
* Since everything within the plugin is registered via hooks, |
| 60 |
* then kicking off the plugin from this point in the file does |
| 61 |
* not affect the page life cycle. |
| 62 |
* |
| 63 |
* @since 1.0.0 |
| 64 |
*/ |
| 65 |
function run_hurrytimer() |
| 66 |
{ |
| 67 |
$plugin = new Hurrytimer(); |
| 68 |
$plugin->run(); |
| 69 |
} |
| 70 |
|
| 71 |
run_hurrytimer(); |
| 72 |
|