Modular page form

I’ve created a modular page and followed the instructions indicated in here

I am able to show the form and the sending emails is working well, then sending emails stopped working when I made another test.

I’m not sure if I made something wrong that I did not spotted immediately.

Here’s my current structure:-

a… I’ve created a modular page and created/used a page file form.html.twig
b… I’ve edited the modular markdown file as per instructions in the documentation and added the following:-

published: true
        dir: asc
        by: default
    items: '@self.modular'
    action: /01.home/_contact/thankyou
    name: contact-form 
        - name: name
          label: Name
          placeholder: Enter your name *
          autocomplete: on
          type: text
          classes: form-name

        - name: email
          label: Email
          placeholder: Enter your email address *
          autocomplete: on
          type: email
        - name: subject
          label: Subject
          placeholder: Subject *
          autocomplete: on
          type: text
        - name: message
          label: Message
          placeholder: Message *
          type: textarea
            required: true

        - name: g-recaptcha-response
          label: Captcha
          type: captcha
          recatpcha_site_key: 6LdUvhITAAAAANuC4X93GfyDX7LOPa7z68C4ESkV
          recaptcha_not_validated: 'Captcha not valid!'

        - type: submit
          value: Submit
        - type: reset
          value: Reset

    - captcha:
        recatpcha_secret: 6LdUvhITAAAAAA8FGshD4R5PL7yoCurL6xciXRwQ
    - email:
        from: "{{ }}"
          - "{{ }}"
          - "{{ }}"
        subject: '[Contact form submission] {{|e }}'
        body: '{% include ''forms/data.html.twig'' %}'
    - save:
        fileprefix: contact-
        dateformat: Ymd-His-u
        extension: txt
        body: '{% include ''forms/data.txt.twig'' %}'
    - display: thankyou

At my site email configuration, I’ve used something like below configuration:-

Mailer: SMTP
Email from:
Email to:
SMTP server: localhost
SMTP port: 25
SMTP encryption: none
SMTP login name:
SMTP password: password
Path to sendmail /usr/sbin/sendmail

Is there something wrong with my structure or is it the email configuration? Please help as I’m trying to work this out for about a day with no luck.

The rest of the form works fine? The values are saved to data/contact-form?

If that part ok, it might be something related to the email settings.

If not, the form.action param must be action: /home

Hi flaviocopes, the data are not saving as well. It’s just redirecting to the thank you page with no action. There’s an error when I tried to change the action path to “/” or “/home”, but it saves the data and the email is working fine, but when I change the action path into the full path of the thank you page, there’s no action, but the thank you page works fine. What is happening?