Support » Plugin: Check & Log Email » PHP Notice if used with PHP7

  • Hey!

    Like this plugin While testing one of my sites on PHP7 I get the following Notice.

    Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; Plugin_Register has a deprecated constructor in /wp-content/plugins/check-email/plugin-register.class.php on line 26

    Can you refactor the constructor to prevent the notice?


Viewing 5 replies - 1 through 5 (of 5 total)
  • Thanks for reporting this, I’ll look into refactoring the constructor. Alternatively send me code and I’ll merge it then credit you as a contributor. Thanks.

    I couldn’t find a github repo to make a PR.

    Take a look at this for more information:


    I had the same issue.

    In wp-content/plugins/check-email/plugin-register.class.php I had to change:

                    // eehmke PHP7 compatibility
                    //function Plugin_Register() {
                    function __construct() {

    In wp-content/plugins/check-email/check-email.php I had to change:

    // eehmke the constructor has been called already by the new operator!   
    // $register->Plugin_Register();

    Works fine for me.

    • This reply was modified 3 years, 11 months ago by eehmke.

    Hi Chris,

    I ran SiteGround’s PHP Config tool (found within their SG Optimizer Plogin) to check PHP 7.0 Compatibility.

    It reported back the following for your plugin:

    Check Email See Errors:
    FILE: /wp-content/plugins/check-email/plugin-register.class.php
    35 | WARNING | Use of deprecated PHP4 style class constructor is not supported since PHP 7.

    Are you planning on making the changes for PHP7 compatibility ?

    Was this fixed in the latest version of your plugin 0.5.5 ?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘PHP Notice if used with PHP7’ is closed to new replies.