• Hi, none of my snippets is working in my installation. WordPress 5.5, Elementor, Neve Theme, Formidable Forms. I´m tring to eliminate an attached file in a thankyou message built in Formidable forms. Tried changing theme, deactivating plugins, deactivating mod security from serve. Any help? Formidable support tells me none of the php hooks is working on my installation.

    This is the code

    add_filter(‘frm_notification_attachment’, ‘remove_my_attachment’, 10, 3);
    function remove_my_attachment($attachments, $form, $args) {
    if ( $args[’email_key’] == 1493) { //change 1277 to the email ID that you would like to DROP the attachment for
    $attachments = array(); //remove all attachments
    }
    return $attachments;
    }

Viewing 1 replies (of 1 total)
  • @juliomarta,

    Sorry this is happening to you. We are currently using 40 snippets with no issues.

    We have learned that if you’re using a snippet and it does not work, the root cause is usually one of the following:

    (1) Improper or outdated PHP code.
    (2) Conflict with another snippet, plugin, or theme.
    (3) Not meeting Code Snippets’ requirements (i.e., WP or PHP level, etc.).

    Have you checked all of the above?

    Cheers!

    PS: BTW, we’re not affiliated with Code Snippets.

Viewing 1 replies (of 1 total)

The topic ‘Snippets not working’ is closed to new replies.