• Stop the server
  • This plugin requires a sql table.Newsletter_Subscribers". Go to the application database and run script for the type of database you are using:
  • Download jars from plugin and add them (ametys-plugin-newsletter-1.x.y.jar and ametys- plugin-newsletter-resources-1.x.y.jar) in the WEB-INF/lib directory of your application. Ametys

  • Add a button to open the newsletter management tool in the WEB-INF/params/cms-ribbon-default.xml. The button identifier is org.ametys.newsletter.userinterface.Newsletters.
    We recommend adding it to the Home tab, in the "Advanced tools" group.

  • In the same file, import the ribbon file specific to newsletters plugin:newsletter://cms-ribbon.xml
<tabs>
    <tab label="RIBBON_TABS_TAB_HOME_LABEL">
        <groups>
            [...]
            <group label="RIBBON_TABS_TAB_HOME_GROUPS_GROUP_ADVANCED_TOOL_LABEL" icon="">
                <large>
                    [...]
                    <control id="org.ametys.newsletter.userinterface.Newsletters"/>
                </large>
                <medium>
                    [...]
                    <control id="org.ametys.newsletter.userinterface.Newsletters"/>
                </medium>
                <small/>
            </group>
            [...]
        </groups>
    <tab>
    [...]
 
    <import>plugin:newsletter://cms-ribbon.xml</import>
</tabs>

Please note! If the group contains a description <large>, <medium> and <small> button must be added to the 3.

 

  • Newsletters have their own workflow (draft, proposed, validated). The validation action sends the newsletter to subscribers.
    Download the workflow description file for newsletters and copy it into the WEB-INF/param directory of your application.
    Then modify the WEB-INF/param/workflows file .xml to add the reference to this file, using the name "newsletter", as shown below:

    <workflows>
      <workflow name="content" type="file" location="workflow.xml"/>
      <workflow name="newsletter" type="file" location="workflow-newsletter.xml"/>
      <workflow name="blog" type="file" location="workflow-blog.xml"/>
    </workflows>
    
  • Restart the server
Back to top

Newsletter