Activation
1 year ago
Admin
1 year ago
Block
1 year ago
Compatibility
1 year ago
Container
1 year ago
Front
1 year ago
Rest
1 year ago
Shortcode
1 year ago
Traits
1 year ago
Widget
1 year ago
Bootstrap.php
1 year ago
Cache.php
1 year ago
Helper.php
1 year ago
I18N.php
1 year ago
Image.php
1 year ago
Output.php
1 year ago
Query.php
1 year ago
Settings.php
1 year ago
Themer.php
1 year ago
Translate.php
1 year ago
WordPressPopularPosts.php
1 year ago
deprecated.php
1 year ago
template-tags.php
1 year ago
Bootstrap.php
26 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Plugin bootstrap file. |
| 4 | */ |
| 5 | namespace WordPressPopularPosts; |
| 6 | |
| 7 | /** Composer autoloder */ |
| 8 | require __DIR__ . '/../vendor/autoload.php'; |
| 9 | |
| 10 | register_activation_hook($wpp_main_plugin_file, [__NAMESPACE__ . '\Activation\Activator', 'activate']); |
| 11 | register_deactivation_hook($wpp_main_plugin_file, [__NAMESPACE__ . '\Activation\Deactivator', 'deactivate']); |
| 12 | |
| 13 | $container = new Container\Container(); |
| 14 | $container->configure([ |
| 15 | new Container\WordPressPopularPostsConfiguration() |
| 16 | ]); |
| 17 | |
| 18 | $WordPressPopularPosts = $container['wpp']; |
| 19 | add_action('plugins_loaded', [$WordPressPopularPosts, 'init']); |
| 20 | |
| 21 | // WPP's template tags |
| 22 | require __DIR__ . '/template-tags.php'; |
| 23 | |
| 24 | // Deprecated functions/classes |
| 25 | require __DIR__ . '/deprecated.php'; |
| 26 |