[Support request] "Posts" pages give php error

Home Forums Support [Support request] "Posts" pages give php error

Home Forums Support "Posts" pages give php error

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
  • #1179162

    For some reason the blogposts give php error.

    I debugged it with deactivating plugins and changing themes. When I deactivate GP Premium plugin. Problem is fixed. But styling is than not correct anymore.

    Customer Support

    Hi there,

    I don’t believe this would be a GP Premium issue.

    Have you added any header or hooks elements?

    If so what happens if you disable them?

    Let me know ๐Ÿ™‚


    Hi Leo,

    Thanks! Thats correct. It has to do with the Custom Post Header it seems. But I haven’t edited it myself. Is there a way to fix this, or could you see what’s wrong with the code?


    $img_src = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), ‘large’, false );
    $categories = get_the_category();
    if ( ! empty( $categories ) ) {
    $cat_name = esc_html( $categories[0]->name );
    global $post


    <h1><?php echo get_the_title($post->ID);?></h1>
    <?php echo ‘term_id ) ) . ‘”>’ . esc_html( $categories[0]->name ) . ‘‘; ?>
    <?php echo ‘‘; ?>
    Customer Support

    Hi there,

    so this is the reason that script is not firing:


    Which may be your default wp-config or something a security plugin has added.

    If you want you can overcome this to allow PHP to be executed in GP Hooks only using the snippet provided here:



    Hi David,

    Thanks for this. Learned a lot again. It’s indeed correct that the define( ‘DISALLOW_FILE_EDIT’, true ); was activated by the security plugin iThemes. I deleted this constant and after re-updating the Element it works again. But without the security measurement. The snippet doesn’t seems to work together with the disallow file edit.

    – I added the snippet using the Cope Snippits plugin, no changes
    – I added the snippet in wp-config.php -> blank page

    Could you maybe suggest some other solutions?

    For now it works again. Thanks!

    Best, Tijn

    Customer Support

    So if you re-enable the iThemes security constant ( so the element breaks )
    And add this to Code Snippets:

    Does it still not work ?


    Yes it works now.

    But I first had to add the Cope Snippet and activate it before re-enabling the iThemes security plugin + constant. Otherwise it doesn’t got it.

    Thanks for all the help!

    Customer Support

    Aah right – i suppose thats good security ๐Ÿ™‚ Thanks for letting us know.

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