If you include a plugin directly inside a theme then it will be rejected by both the WordPress.org theme directory and ThemeForest.
You should use TGMPA for including plugins with themes: http://tgmpluginactivation.com/
Further reading: http://code.tutsplus.com/tutorials/using-the-tgm-plugin-activation-library-in-your-themes–cms-20901
Using TGMPA means the plugin remains a plugin, WordPress loads it in the normal ‘plugin’ way, and users will get plugin updates as they’re released.
Related Posts:
- How to call “page specific menu items” in template [closed]
- How do I make my wordpress page more friendly for mobile viewers?
- Check javascript file Proper way in functions.php
- Should I use RIPS tool to test my themes and plugins?
- Workflow and best practice for documentation [closed]
- Is there a quick way to inject i18n domain into theme/plugin files?
- Translating plugin inside the theme [closed]
- Why are some of my thumbnails not being generated?
- Making menu link open in new tab?
- wordpress theme backend admin only
- Menus, but not by theme location
- How to get current post user id
- Different UI in WordPress
- The problem with WordPress Importer
- Classified ad website : which solutions to use? [closed]
- Finding the URL to be used to check if plugin is installed with a theme
- How can I position ShareThis buttons manually when using the plug-in? [closed]
- How to use get_template part in the plugin?
- Redirect to another page using contact form 7? [closed]
- How do I combine a theme with a plugin
- How to write “alt” tag in image for wordpress code?
- How to get menu location in wp_update_nav_menu hook
- Use different single.php file based on condition
- Include Minit plugin in theme [closed]
- How can I use my custom wordpress theme on two websites? [closed]
- why need theme,if page builder is there in wordpress [closed]
- Inserting Plugins Into Blank Space of Externally Designed WordPress Theme
- Don’t load the theme for a page FROM a plugin EDITED
- Extending a theme: build new features as plugin or core modules?
- how to design change in woocommerce cart page and all other page also by theme? [closed]
- display unique post per category
- How do you create a re-useable HTML fragment in wordpress
- navigation among single posts
- Identify current wordpress theme
- Removing the custom_image_header from wp_head
- Elementor Sidebar not loading when PRO elements plugin is active
- How to override any plugin file in the child theme
- Mobile Menu and Mobile Sidebar missing
- How to get a post views count using ‘WordPress popular posts’ plugin
- WordPress site hamburger menu toggle not working
- when i activate my WordPress plugin cannot see customizer options or preview
- Showing different js file for different theme in wordpress customizer api
- WordPress panel is not loading after plugin activated with error: HTTP ERROR 500
- When the user entered an unauthorized url redirect to login page
- how to add custom css at top above all css file for specific url
- How can I add a custom checkbox / radio button on the admin theme options to display a CSS or other?
- Why the output of an image gallery plugin is not displayed into a page of my custom theme?
- Disqus plugin outputs script as literal text
- Breadcrumb is not generating the correct post page url
- How can I add different menus (different style menu) on each page?
- Site is setup statically – how to make it content managable?
- How to work email subscribe in WordPress?
- Javascript as Jquery Function Call?
- Editing a theme
- How to escape html code?
- How to create an Info Box on WordPress [closed]
- How to make content as required in custom post type?
- Prevent primary navigational menu from expanding during page load (WordPress / Astra Theme)
- Hide wordpress plugins from list
- Declare a function before plugin does on the theme functions.php file
- Custom wp_nav_menu output (displaying all child elements of top menu element in current branch)
- Displaying wp menus by name without using theme locations
- How to use load_plugin_textdomain from within a theme
- Autoload via composer in plugin interference
- WordPress language switcher
- Set WordPress Featured Image For All Post Slugs Matching Image File Name in Specified Directory
- Showing Co-Authors on post page
- How does WP handle multiple matching rewrite rules?
- Do I still need a theme to use page builders?
- Can I make a super plugin that also has a theme?
- Not getting author rank when using return
- Creating a nav menu
- Check for security updates
- All sites themes functions.php have been changed
- Customizing Titles on the Fly with Code
- Is it possible not to load theme on a specific page in wordpress?
- I receive taxonomy id
- Managing wordpress Themes & plugins for multisite
- How to include files relative to a file’s directory
- Blocking Plugin Css to load custom in template directory
- Some doubts about WordPress handle the horizontal main menu visualization
- Display WordPress comments before the plugins?
- Mobilepress fails to translate short codes
- uncaught TypeError: Cannot read properties of null (reading ‘classList’) custom plugin
- Slideout submenu in mobile
- Display posts by alphabetical order
- custom fields not displaying on wordpress site
- Can’t add new plugin or themes on a wordpress multisite network from the primary site as administrator. Error: ERR_TOO_MANY_REDIRECTS
- Theme: dropdown hover menu not showing up in IE/Edge
- Using Shortcode Result In Custom HTML Block (Using Google Sheet JQuery Result As NumScroller data-max)
- How to prevent redoing get_posts queries and make results available to other scripts?
- Is it possible to disable a theme programmatically?
- Product catalogue in WordPress
- What Are the Advantages of Using an mu-plugin
- Things that saved lose when logout
- Category archive in menu
- My wp_update_nav_menu action is firing twice
- Ajax button “Load more” is not loading correct language version posts for logged out users
- How to code a wordpress page properly? Dashboard or unique Theme files or alternative?
- how to make wordpress remember my choice