• Resolved jamminjames

    (@jamminjames)


    I used the PHP Compatibility Checker plugin to check my site, and for PHP 7.0, there are 7 warnings and one error for this plugin.

    Such as these for various files within the plugin:
    Method name “PrisnaGWTFastJSON::__getStaticReplacement” is discouraged; PHP has reserved all method names with a double underscore prefix for future use.
    File has mixed line endings; this may cause incorrect results.

    The error is for the common.class.php file:
    preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since PHP 7.0

    Is it compatible with PHP 7.0? Are these issues being addressed?

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Prisna

    (@prisna)

    Greetings,

    yes, the plugin works on PHP 7.

    These are not really issues, just warning messages issued by a 3rd party plugin. It’s true that PHP has reserved all method names with a double underscore prefix; but it’s nearly impossible they will ever create a method named __getStaticReplacement, currently these PHP magic methods are:

    __construct(), __destruct(), __call(), __callStatic(), __get(), __set(), __isset(), __unset(), __sleep(), __wakeup(), __toString(), __invoke(), __set_state(), __clone() and __debugInfo()

    So there’s no need to worry. In any case, we’ll change the method name and regular expression in the next plugin update.

    Regards

    • This reply was modified 7 years, 10 months ago by Prisna.
    Thread Starter jamminjames

    (@jamminjames)

    Great, thanks!

    Although, you didn’t address the error, which the report says is more serious:

    common.class.php file:
    preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since PHP 7.0

    …but if, as you say, it’s working with 7.0 now, I assume that it’s not fatal, and that it will be addressed as well, right?

    Thanks again.

    Plugin Author Prisna

    (@prisna)

    Greetings,

    we did address it, but perhaps it wasn’t obvious enough. The regular expression comment referred to the preg_replace function.

    Regards

    @prisna, I’m trying to determine whether that regular expression error should hold us back from upgrading one of our sites to PHP 7.0. What is your timeframe for releasing the next update? Thank you!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Compatible with PHP 7.0?’ is closed to new replies.