• Resolved mmorris8

    (@mmorris8)


    PHP Warning:  Constant DISALLOW_FILE_EDIT already defined in phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1334) : eval()'d code on line 138

    Apparently the WP_CLI itself is setting the DISALLOW_FILE_EDIT constant, so AIOS needs to check to see if the constant was already set before trying to set it.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support hjogiupdraftplus

    (@hjogiupdraftplus)

    Hi @mmorris8,

    There is an internal ticket for this issue being worked on.

    I will get back to you soon on this.

    Regards

    Plugin Support hjogiupdraftplus

    (@hjogiupdraftplus)

    Hi @mmorris8

    If I cross check the error raised during the WP CLI Get the wp-config code and eval( $this->get_wp_config_code() );

    So before that somewhere else the constant might be defined + AIOS setting constant that can be the issue.

    https://github.com/wp-cli/wp-cli/blob/main/php/WP_CLI/Runner.php#L1335

    We have worked on the fix for the Constant DISALLOW_FILE_EDIT already defined warning.

    Can you please upload the zip as Add a new plugin and replace it with the existing AIOS plugin?

    https://gofile.io/d/HRCB6v

    Please turn off the Disable ability to edit PHP files: feature once from the
    WP security > File Security > File protection tab and remove the
    DISALLOW_FILE_EDIT defined false constant in the wp-config.php

    Then refresh the WP security > File Security > File protection tab you might can see the warning.
    turn on the Disable ability to edit PHP files: feature.
    It will add below so there will not be any such error by AIOS

    if (!defined('DISALLOW_FILE_EDIT')) { define('DISALLOW_FILE_EDIT', true); }

    Please let me know if still there the issue. This fix is going to be in next release of AIOS Free.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.