Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- require_once dirname( __FILE__ ) . '/inc/class-tgm-plugin-activation.php';
- add_action( 'tgmpa_register', 'my_theme_register_required_plugins' );
- function my_theme_register_required_plugins() {
- $plugins = array(
- // This is an example of how to include a plugin bundled with a theme.
- array(
- 'name' => 'Nazmul-hasan-toolkit',
- 'slug' => 'Nazmul-hasan-toolkit',
- 'source' => get_stylesheet_directory() . '/inc/plugins/Nazmul-hasan-toolkit.zip',e.
- 'required' => true,
- 'version' => '1.0',
- 'force_activation' => true,
- 'force_deactivation' => true,
- ),array(
- 'name' => 'WPBakery Visual Composer',
- 'slug' => 'Js-Composer',
- 'source' => get_stylesheet_directory() . '/inc/plugins/Js-Composer.zip',e.
- 'required' => true,
- 'version' => '1.0',
- 'force_activation' => true,
- 'force_deactivation' => true,
- ),
- // This is an example of how to include a plugin from the WordPress Plugin Repository.
- array(
- 'name' => 'Breadcrumb NavXT',
- 'slug' => 'breadcrumb-navxt',
- 'required' => true,
- 'version' => '5.7.1',
- ),
- array(
- 'name' => 'Contact Form 7',
- 'slug' => 'contact-form-7',
- 'required' => false,
- 'version' => '4.7',
- ),
- );
- $config = array(
- 'id' => 'stock',
- 'default_path' => '',
- 'menu' => 'stock-install-plugins',
- 'parent_slug' => 'themes.php',
- 'capability' => 'edit_theme_options',
- 'has_notices' => true,
- 'dismissable' => true,
- 'dismiss_msg' => '',
- 'is_automatic' => false,
- 'message' => '',
- );
- tgmpa( $plugins, $config );
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement