Magnolia 5.3 reached end of life on June 30, 2017. This branch is no longer supported, see End-of-life policy.

Page tree
Skip to end of metadata
Go to start of metadata

 

The Campaign Importer app allows you to import static HTML files and related resources (CSS, JS) into Magnolia and convert them to pages. Use the app to  deploy marketing campaigns that are authored outside Magnolia.

Please note that in the current versions CSS files can't have absolute paths references to images. 

 

What is a campaign?

Marketing campaigns typically have a very short lifespan. A campaign promotes specific products or services and is decommissioned after the campaign ends. A marketing agency commonly creates the campaign outside of Magnolia and delivers it as static HTML pages. Integrating such as campaign into Magnolia usually requires the services of an IT professional or developer.

The Campaign Importer app eliminates this need, allowing marketers to import and publish marketing campaigns without IT support.  The campaign can then take full advantage of Magnolia's features such as integrated marketing tags management , multilanguage support, A/B testing using page variants and personalization .

Configuration

The Campaign Importer app is installed by the Campaign Importer module. The app is located at Configuration > /modules/campaign-importer/.

Node name

 modules

 campaign-importer

Workspace

The app operates on the campaigns workspace where campaign content is stored.

Node types

The Campaign Importer module registers a custom mgnl:campaign node type. The app operates on nodes of this type.

Importing a campaign archive

To import a campaign archive:

  1. Open the Campaign Importer app.
  2. Click Import Campaign.
  3. Browse to a .zip archive that contains the static campaign content.
  4. Click Save changes.

The archive contents are displayed in the app.

 

Campaign archive file format

The app imports campaign files as a compressed archive (.zip) and creates a Magnolia node structure that matches the internal structure of the archive. HTML files are at the archive root and CSS, JavaScript and image files in separate directories.

css/
js/
images/
fonts/
index.html
register.html
thanks.html

While this is the typical structure the App can also import campaigns that are structured differently. For example, if a campaign archive contains a large number of HTML pages structured into separate subfolders the app will respect this structure and create a similar representation in the Magnolia content tree.

Info

Please note the your zip file needs an index.html file


Creating campaign pages

To create pages from the imported files:

  1. Select the imported campaign and click Create Pages.
  2. Select a node in the content tree under which you want to create the campaign pages. To create pages at the root level type / (forward slash).
  3. Open the Pages app to view the created pages.

Resources

When you create the pages the app also creates dependent resources such as CSS and JavaScript in the resources workspace. You can find them in the Resources app.

Editing and publishing campaigns

You can edit the campaign pages just like normal pages in the Pages app:

  1. Optional: Assign a different template to a campaign page.
  2. Edit a page to change its content.
  3. Publish.

 Installation

To install the Campaign importer App add the following dependency to your webapps POM.xml

<dependency>
  <groupId>info.magnolia.campaignimporter</groupId>
  <artifactId>magnolia-module-campaign-import</artifactId>
  <version>1.1.8</version>
</dependency>

Pre-built jars are also available for download. See Installing a module for help.

magnolia-module-campaign-import-1.1.8.jar