[wp-trac] [WordPress Trac] #23880: Minimum PHP version in Plugins
WordPress Trac
noreply at wordpress.org
Fri Mar 29 03:35:52 UTC 2013
#23880: Minimum PHP version in Plugins
-----------------------------+------------------------------
Reporter: TJNowell | Owner:
Type: feature request | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Plugins | Version:
Severity: normal | Resolution:
Keywords: |
-----------------------------+------------------------------
Comment (by MikeSchinkel):
Replying to [comment:19 TJNowell]:
> If I write a plugin that uses namespaces and someone finds it and
installs it on a server running 5.2, it will fail. It should instead
degrade gracefully and warn the user. The user should be able to see ''"oh
I have 5.2, it needs 5.3"'' and choose whether to upgrade or pick another
plugin.
Maybe I'm missing something but your plugin can resolve this issue on it's
own. Have your main file `version_compare()` for PHP 5.3 before
`require()`ing any files that contain namespaces and if PHP 5.2.x then
tell the user and [http://grinninggecko.com/activating-deactivating-
wordpress-plugins-programmatically/ deactivate the plugin]. Does this not
work for some reason I have not considered?
--
Ticket URL: <http://core.trac.wordpress.org/ticket/23880#comment:20>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list