• Resolved cmsbuttler

    (@cmsbuttler)


    Hello GiveWP Support Team,

    I am currently experiencing an issue with a GiveWP donation form on our website and would appreciate your assistance.

    When submitting the donation form, the browser console returns the following error:

    “Unexpected token ‘<‘, “{“data””… is not valid JSON”

    It appears that the AJAX response expected by GiveWP is returning HTML (starting with a <p> tag) instead of valid JSON. Because of this, the JavaScript JSON parsing fails and the donation form cannot complete the request properly.

    Website:
    https://sv-froemmersbach.de/spenden/

    Additional observations from the browser console:

    • JSON parsing error when submitting the donation form
    • Error message indicating HTML content (<p>) before the JSON response
    • In some cases the console also shows:
      JSON.parse: unexpected character at line 1 column 1 of the JSON data

    Environment details:

    • WordPress with Elementor
    • GiveWP donation form embedded on the page above
    • The response appears to contain HTML before the JSON output

    Could you please advise:

    1. What might cause HTML (such as <p>) to be prepended to the GiveWP JSON response?
    2. Whether this could be related to a known GiveWP issue or a common plugin conflict?
    3. What the recommended debugging steps would be to identify the source of the invalid output?

    If needed, I can also provide the full AJAX response and additional debugging information.

    Thank you very much for your support.

    Best regards
    Andreas Rudolph

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Ginger Coolidge

    (@gscoolidge)

    Hello @cmsbuttler ,

    Glad you reached out, happy to help.

    Normally that error is most often related to caching, however, I don’t see any caching on that page.

    To get a better idea of what is happening, we’ll need to see the form log for when the error occurred.

    Every time a donation is made on your site – or attempted, GiveWP creates a new entry in the logs section that provides additional information on what is happening. The error logs are accessed by going to GiveWP > Tools > Logs. You’re looking for entries for the date/time of the donation attempts that generated that error. If find one, click on the “eyeball” icon on the right of the log to expand it to view the contents.  After that, copy/paste the complete log into your next reply. (Note: a screenshot will not show us enough information. Here’s a quick (silent) screencast on how to get the form error log content for us: 

    Looking forward to guiding you to a solution here! 🙂

    Thread Starter cmsbuttler

    (@cmsbuttler)

    Hello @gscoolidge

    there are no logs 🙁

    No data

    Plugin Support Ginger Coolidge

    (@gscoolidge)

    Hello @cmsbuttler ,

    Thanks for the update!

    We would like to dig deeper to understand what is happening with GiveWP on your site.

    To do that, please reach out to us via our contact form at https://givewp.com/contact-us/? Use the option that says “I am responding to a request to contact you.” Provide the link to this thread as context, your system info, etc. and we will happily help you.

    The system information is in GiveWP > Tools > System Info (tab), click the button to Get System Report and copy/paste ALL of the text in your email reply.  Here is a (silent) video showing you were to find and copy this info.

    https://www.loom.com/share/cc68cd6b3ecf4b32b28f3d6656291ba4

    I’m marking this as resolved here for now. I’ll post an update of the solution if applicable.

    Best regards,

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.