We've had php execution enabled in our custom theme elements defined via "Elements".
The plugin "Defender" added a line define( 'DISALLOW_FILE_EDIT', false ); in the wp-config.php which led to all the snippets containing php being broken. Custom elements showed a hint: "Unable to execute PHP as DISALLOW_FILE_EDIT is defined."
Steps to reproduce
Add define( 'DISALLOW_FILE_EDIT', false ); to your wp-config.php
OR
Activate Defender plugin
Store normal settings with "Disable the file editor" inactive
Actual behavior
DISALLOW_FILE_EDIT set to false disables php execution.
Expected behavior
DISALLOW_FILE_EDIT set to false should not disable php execution, only if it's set to true.
Description
This is regarding GeneratePress Version 3.3.1
We've had php execution enabled in our custom theme elements defined via "Elements". The plugin "Defender" added a line
define( 'DISALLOW_FILE_EDIT', false );
in thewp-config.php
which led to all the snippets containing php being broken. Custom elements showed a hint: "Unable to execute PHP as DISALLOW_FILE_EDIT is defined."Steps to reproduce
define( 'DISALLOW_FILE_EDIT', false );
to yourwp-config.php
OR
Actual behavior
DISALLOW_FILE_EDIT
set tofalse
disables php execution.Expected behavior
DISALLOW_FILE_EDIT
set tofalse
should not disable php execution, only if it's set totrue
.References