[Support request] define( 'GENERATE_HOOKS_DISALLOW_PHP', true );

Home Forums Support define( 'GENERATE_HOOKS_DISALLOW_PHP', true );

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #434982
    Edwin

    Hi Tom

    After adding “define( ‘GENERATE_HOOKS_DISALLOW_PHP’, true );” to wp-config i found that execute PHP under GP hooks stopped working.

    After i removed it from wp-config it start working again.

    Thanks

    Edwin

    GP Premium 1.5.5
    #435033
    Roman

    Yes, that is exactly the behavior expected by defining define( ‘GENERATE_HOOKS_DISALLOW_PHP’, true ); in wp-config – the execution of php in hooks is prevented then. 🙂

    So what exactly was your concern? Why did you want to make this entry?

    Maybe this reading this entry will help you:
    Disallow PHP Execution

    However, if you just want to hide the red admin hint, then paste the following code into your child theme’s functions.php:

    add_action( 'after_setup_theme', 'tu_remove_hooks_php_check' );
    function tu_remove_hooks_php_check() {
        remove_action( 'admin_notices','generate_hooks_php_check' );
    }
    #435114
    Leo
    Staff
    Customer Support
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.