PHP7 Compatibility – scan for code that is used for backward compatibility
-
“PHP Compatibility Checker” was used to scan the following plugins (there may be more later) ;
ManageWP – Worker
Postie
Both got reported as warnings and some errors, because they used code of older versions of PHP.
However, although they contain older commands, those commands are in theportions of code that get used if older PHP versions are detected by the plugin.So some suggestions for features and functions
It would be very useful when doing a scan, to include the search for signature type code that does the following ;
a) detect PHP versions
b) makes decisions about what to do if a version is detected
c) encases respective code for respective versionsAdditional Features ;
The scan report could note that the plugin is also attempting to be compatible with the detected other versions.
The user may choose to set the scan to actually check the compatibility with the other versions that the plugin is attempting to be compatible with, or not.
The scan could make a note in the report that the plugin authors are showing extra effort in maintaining more universally applicable code.
The scan may also check the accuracy of the code for (a,b,c) above in doing their tasks (there may be standard procedures for this).
- The topic ‘PHP7 Compatibility – scan for code that is used for backward compatibility’ is closed to new replies.