• Resolved vanclvr

    (@vanclvr)


    I ran a PHP Compatibility check, moving from 5.4 to 7.2, and received 9 warning:

    ———————————————————————————————————-
    FOUND 0 ERRORS AND 9 WARNINGS AFFECTING 9 LINES
    ———————————————————————————————————-
    68 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    69 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    70 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    71 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    72 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    73 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    74 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    75 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    92 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
    ———————————————————————————————————-

    Is the function “create_function()” a core element to this plugin and are there any steps to avoid errors when upgrading? The PHP 5.4 thru 7.0 is being depreciated with no support by end of month, so will need to update but would like to still use this plugin!

    Thank you!!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Steven

    (@shazahm1hotmailcom)

    @vanclvr

    The “create_function()” is only being deprecated and the warning you are seeing if for developers only so they can plan on removing use of the deprecated function over time. This function will likely remain in PHP for nearly a decade before being removed.

    So, that said … yes, the calls to the “create_function()” will be removed and Connections should work just fine on PHP 7.2 and 7.3 as is.

    In regards to potential warnings being displayed on your site. It is a best practice on live production sites to suppress PHP warning and errors. Personally, I log them to a folder/file which is not publicly accessible. Warnings and errors should only ever be displayed on dev sites or while the site is under construction.

    I hope this help!

    Thread Starter vanclvr

    (@vanclvr)

    @shazahm1

    Thank you, this helps!!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Upgrade to PHP 7.2’ is closed to new replies.