WordPress.org

Support

Support » Plugins and Hacks » Forms: 3rd-Party Integration » [Resolved] How to show an error message from on_response_error or remore_failure?

[Resolved] How to show an error message from on_response_error or remore_failure?

  • GlennPiper

    @glennpiper

    Hi!

    I am unable to get this plugin to ever show an error.
    I finally traced out that the “on_response_error” method is being called as I would expect it to, but that it does nothing to actually show the user any form of error message.
    The original plugin seemed to alter some “additional_settings” of Contact Form 7 to try to show a message, but I have not been able to get that to work either.
    Can anyone help me determine how inform the user that an error occurred in a nice way that allows them to update and resubmit their form?

    Thanks!

    http://wordpress.org/plugins/forms-3rdparty-integration/

Viewing 2 replies - 1 through 2 (of 2 total)
  • GlennPiper

    @glennpiper

    Ok, I think I found a bug here…

    In the “forms-3rdparty-integration.php” file, I can see in the “on_response_failure” function that it is supposed to call the hook “remote_failure”. In my case, since I am using Contact Form 7, this calls the “remote_failure” method in the “contactform7.php” file. Or, at least it should.
    For some reason I do not yet understand, it logs an error when attempting the “apply-filters” call in “on_response_failure”, indicating that the function is expecting the first parameter to be passed by reference, but that it was being passed by value. I was only able to get it to run by altering the “remote_failure” function to take it’s parameters by value (i.e. remove the & before each parameter).
    Note: this also needed to be done to the “remote_success” method to get it to work.

    FWIW, I am using WP 3.7.1 and PHP 5.4.4

    Hope this helps someone else…

    Plugin Author zaus

    @zaus

    Hey thanks for catching that — it’s a PHP 5.4 issue, and I’ve been working under 5.3.

    The latest version v1.4.6 should have those fixes you mentioned.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] How to show an error message from on_response_error or remore_failure?’ is closed to new replies.
Skip to toolbar