• Hi everyone,
    I have a site with the Astra 3.9.1 theme and after upgrading Contact Form 7 to version 5.6 (or 5.6.1), the validation stopped working. When I submit a form with incorrect data, the red messages under each field do not appear, in addition the message in the yellow border at the bottom is blank.

    The error is visible in the console:
    index.js:1 TypeError: Cannot read properties of null (reading ‘querySelector’)
    at l (index.js:1:2551)
    at Array.forEach (<anonymous>)
    at index.js:1:3708

    After restoring Contact Form 7 to version 5.5.6.1, everything is back to normal. I also added “define( ‘WPCF7_LOAD_JS’, false );” to wp-config and this also helped, but disabled the dynamic messages.

Viewing 1 replies (of 1 total)
  • I’m also running Astra (child theme). This appears to have stopped working at some point after July 4th. I’ve tried the changes @kamilb11 mentioned, without any success.

    For me, it’s the state field breaking things. When I remove State from being required (and still fill it in), the form is allowed to parse, but state never gets saved (I’m also using the Contact Forms 7 DB plugin).

    This is true for 5.5.6.1, 5.6 and 5.6.1. I suspect the Astra theme might be causing this conflict, but am unsure.

    FYI, here’s the code I’m using for this form (a snippet):

    	<div class="cdrBox2">[text* your-name placeholder "Mailing Name*"]</div>
    	<div class="cdrBox2">[email* your-email placeholder "Email* (e.g. [email protected])"]</div>
    	<div class="cdrBox2">[text* address placeholder "Street Address*"]</div>
    	<div class="cdrBox2">[text* city placeholder "City*"]</div>
    	<div class="cdrBox2">[text state placeholder "State*"]</div>
    	<div class="cdrBox2">[text* zip placeholder "Zip Code*"]</div>
Viewing 1 replies (of 1 total)
  • The topic ‘Validation is not working properly from 5.6 version’ is closed to new replies.