validate_plugin_requirements ( $plugin )

  • (string) plugin Path to the plugin file relative to the plugins directory.
  • (true|WP_Error) True if requirements are met, WP_Error on failure.
Defined at:
Change Log:
  • 5: .


Validates the plugin requirements for WordPress version and PHP version.Uses the information from `Requires at least` and `Requires PHP` headers defined in the plugin's main PHP file. If the headers are not present in the plugin's main PHP file, `readme.txt` is also checked as a fallback.

Related Functions

validate_theme_requirements, validate_plugin, validate_active_plugins, wp_validate_redirect, validate_username

Top Google Results

User discussions

wpseek mobile