Minimum PHP version in Plugins
|Reported by:||TJNowell||Owned by:|
If I write a plugin that uses namespaces, and test locally and find no issues, everything is okay for me.
However namespaces is a PHP 5.3 feature, and a significant portion of the userbase is on 5.2.x.
Given the rise of PHP 5.3 usage, and oncoming 5.4 features, I'd like to be able to declare that such a plugin requires PHP 5.3 minimum else it will break, and for WordPress to respect this if the plugin is installed on a 5.2.x server by preventing activation of a plugin that is guaranteed to cause a fatal error as a result.
e.g. for one of my own plugins:
<?php /* Plugin Name: Local Indicator Plugin URI: http://tomjn.com Description: Indicates the current server used via a colour coded IP in the top admin bar, useful for telling live and Local dev environments apart Author: Tom J Nowell, Interconnect/IT Version: 1.3 Minimum PHP: 5.3 Author URI: http://tomjn.com/ */
Change History (41)
comment:18 @dh-shredder — 2 years ago
- Cc mike.schroder@… added
comment:24 in reply to: ↑ 23 @F J Kaiser — 2 years ago
comment:32 @markoheijnen — 2 years ago
- Keywords close removed
- Milestone Awaiting Review deleted
- Resolution set to worksforme
- Status changed from new to closed
comment:40 in reply to: ↑ 34 @F J Kaiser — 6 weeks ago
- Resolution wontfix deleted
- Status changed from closed to reopened