validate_plugin_requirements
validate_plugin_requirements ( $plugin )
Parameters:- (string) plugin Path to the plugin file relative to the plugins directory.
Returns:- (true|WP_Error) True if requirements are met, WP_Error on failure.
Defined at:Change Log: - Introduced in WordPress: 5.2.0
- Deprecated in WordPress: —
Description
Validates the plugin requirements for WordPress version and PHP version.Uses the information from `Requires at least`, `Requires PHP` and `Requires Plugins` headers
defined in the plugin's main PHP file.