• Unfortunately this Plugin broke me website by using PHP Code. I couldn’t deactivate the Code Snippet so i had to uninstall the Plugin.

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

    (@bungeshea)

    This plugin gives you the freedom to create your own snippets, but unfortunately this means that the responsibility for not writing bad code that breaks your site is on you.

    We include a safe mode feature to make it easy to recover from issues like this without needing to uninstall the plugin. You can read more about it here: https://help.codesnippets.pro/articles/12-safe-mode

    I’d definitely recommend exploring the existing resources for solutions like these or asking a question in the support forum when you encounter issues in the future, instead of jumping straight to the review section.

    Plugin Author Shea Bunge

    (@bungeshea)

    Apologies, I posted the wrong URL. The correct link is https://help.codesnippets.pro/article/12-safe-mode

    Actually, the code I was using when the site broke was valid:

    <?php if( get_field('subtext') ): ?>
    <p><?php the_field('subtext'); ?></p>
    <?php endif; ?>

    So I’m not sure how this simple piece would’ve caused the site to break.

    Sven71

    (@roaddoc)

    My wild guess: it broke because of the PHP tags. You are not working in a HTML editor here that would demand the tags. You do work in a PHP editor and especially the closing PHP tag cuts off further PHP code outside your snippet which easily breaks sites.
    Please take a first attempt at omitting PHP tags and report back the result.

    • This reply was modified 2 years ago by Sven71.
    Sven71

    (@roaddoc)

    As a starter:

    $subtext = get_field( ‘subtext’ );
    if ( $subtext ) {
    $response = ‘<p>’ . esc_html( $subtext ) . ‘<p>’;
    echo $response; // output the HTML
    }

    Nothing more. No PHP open / close tags in code snippet editor to be added by you.

    toad78

    (@toad78)

    Thank you, @roaddoc.

    Unfortunately, that wasn’t the situtation when I attempted to use it.

    Sven71

    (@roaddoc)

    Hm, I don’t remember Code Snippet to work otherwise ever and I’ve used it for years now. Anyhow, if the problem is solved whatever way then I guess this thread can be closed.

    Plugin Author Shea Bunge

    (@bungeshea)

    Hi @toad78,

    This is a review, not a support thread. If you’d like some assistance with using the plugin, we’d be happy to help, but we do ask that each issue has its own thread to make things easier to follow.

    Plugin Contributor Verdi Heinz

    (@ver3)

    Hello @deno1, Thank you for leaving a review of our product. We appreciate your feedback, and we’re sorry to see that you left a low rating. We always strive to provide a great user experience, and we want all of our customers to be happy with our product.

    We hope the support you received here led to a solution. If there is any other thing that we can do to improve your experience, please let us know.

    Also, we would like to mention that our product is completely free of charge, and we hope that this may encourage you to reconsider your rating as it means a lot to a small team like ours.

    Thank you again for choosing our plugin, we look forward to serving you in the future. Kind regards, Verdi

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Breaks Site, can’t deactivate Snippet’ is closed to new replies.