redirect-redirection
Last commit date
assets
4 years ago
includes
4 years ago
activation.php
4 years ago
index.html
4 years ago
readme.txt
4 years ago
redirect-redirection.php
4 years ago
uninstall.php
4 years ago
activation.php
29 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * This file is loaded only on plugin's activation |
| 5 | */ |
| 6 | if (!defined("ABSPATH")) { |
| 7 | exit(); |
| 8 | } |
| 9 | |
| 10 | /** |
| 11 | * Load contants and database manager |
| 12 | */ |
| 13 | include_once "includes/irrp-constants.php"; |
| 14 | include_once "includes/irrp-db-manager.php"; |
| 15 | |
| 16 | /** |
| 17 | * Make new database manager and try to create DB tables if does not exist |
| 18 | */ |
| 19 | $iRdbManager = new IRRPDBManager(); |
| 20 | $iRdbManager->createTables(is_multisite()); |
| 21 | |
| 22 | /** |
| 23 | * Mark activation option |
| 24 | */ |
| 25 | update_option('irrp_activation_redirect', true); |
| 26 | if (!defined('IRRP_ACTIVATION_REQUEST')) { |
| 27 | define('IRRP_ACTIVATION_REQUEST', true); |
| 28 | } |
| 29 |