Setup newsletter plugin


I found this newsletter plugin
But I am new to grav and not quite sure how to set it up. Got it running in the admin panel but I have no idea how to integrate the form in the client page.

Would be great if anyone can help me with that! :slight_smile: Sadly there is zero documentation for this plugin…

Hi, in principle after you activated the Newsletter plugin, you need to set up a page like . The frontmatter in our case looks like

title: Newsletter

- name: name
label: Name
placeholder: Enter your name
autofocus: on
autocomplete: on
type: text
required: true

    - name: email
      label: Email
      placeholder: Enter your email address
      type: email
        required: true 

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

    - subscribe:
        filename: newsletter.txt
        operation: add

Note the `subscribe` action. Maybe you need to adjust the settings a bit, since I haven't tested it.

Concerning the plugin, consider it as "pre-alpha" release, since it is not included in the GPM and thus may contain some bugs or even security issues... Further although recently created, it seems to be abandoned for me.

I second Sommerregen, would be nice to have such plugin well documented and in the GPM.

Currently I would just use (and I do use myself) some JS from a service that provides newsletters and a js-based form collection which automates the opt-in. You add it to the theme’s twig, and you’re set.

Hi, thanks for the answers! :slight_smile:
Yep, I also thought using something like Mailchimp would be better for now. But thanks Sommerregen for the great explanation, helped me to better understand grav! :slight_smile: