Support » Plugin: Code Snippets » Custom PHP code shown as HTML

  • Resolved typoerorr


    Hi there,

    I am using Code Snippets and Insert PHP together with the Montezuma theme.

    The pages are able to resolve the PHP to generate dynamic content.

    However, the interesting thing is that the page also shows my PHP codes after the dynamic content.

    You can view it here

    Have everyone encountered this after upgrading to the latest version of Snippets?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Shea Bunge


    I tried using the Insert PHP plugin along with Code Snippets on the Montezuma theme, and it works fine. This means that it must one of your snippets that is messing something up.

    Try adding the line

    define('CODE_SNIPPETS_SAFE_MODE', true);

    to your wp-config.php file (just under the WP_DEBUG line). Does the problem still occur? If not, then remove this line and go through activating your snippets one-by-one to see which one messes things up.

    If the problem is still happening, even with the line in wp-config.php, then it’s not your snippets causing the problem. Try deactivating the Code Snippets plugin and see what happens.

    I have deactivated Code Snippets plugin but the problem still persists.

    The issue seems to be with the loop function generating the queries from the database.

    I will have to figure it out. Thanks.

    I manage to resolve the issue by using Allow PHP in Posts and Pages plugin instead of Insert PHP plugin. Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Custom PHP code shown as HTML’ is closed to new replies.