How to export and import AAM settings

This article explains how to export AAM settings and import them to different site. This feature is available with AAM 4.9 and higher. Please note, this is the initial version of the feature and any feedback is highly appreciated.

Export/Import AAM settings

Upon numerous requests from our loyal customers, we made the decision to add the ability to export and import AAM settings. Additionally our objective was to give the full control over what settings user wants to export and below you can find all necessary details to effectively customize and use export/import feature.

First of all we added two additional buttons to the Utilities tab under Tools section and, by default, the Export button exports list of all roles, capabilities and utilities settings. The downloaded file is a simple text file with JSON object that looks similar to this:

{
  "version": "4.8.1",
  "plugin": "advanced-access-manager",
  "datetime": "2017-07-22 21:44:33",
  "metadata": {
    "system": "roles,utilities"
  },
  "dataset": {...}
}

It is important to mention that export/import feature may not work properly with older browsers and it is preferable to use one of the latest Firefox, Chrome or Opera browser. It will not work with Internet Explorer and Safari browsers as they do not support the latest HTML5 features that we use for export/import functionality.

AAM has over 100 different features and settings and that is why sometimes you would what to customize what exactly is needed to be exported. That is why all AAM settings are split onto 5 buckets:

  • system bucket holds list of roles, capabilities, AAM utilities setting;
  • roles bucket holds all settings related to roles;
  • users bucket holds settings related to all users;
  • visitor bucket holds all settings related to visitors
  • default bucket holds all the default settings

In order to customize the AAM export feature, you would need to install free ConfigPress extension that you can find on the Extensions tab under the Free section. Upon installation, you can go to the ConfigPress tab and redefine AAM export feature. Below is the example of the configurations that export all AAM settings:

[aam]
export.system = "roles,utilities,configpress"
export.roles = "menu,metabox,post,redirect"
export.users = "menu,metabox,post,redirect,capability"
export.visitor = "metabox,post,redirect"
export.default = "menu,metabox,post,redirect"

From the configurations above you might already figured out, that for example for all users you want to export menu (Admin Menu), metabox (Metaboxes & Widgets), post (Posts & Pages), redirect (Access Denied Redirect, Login Redirect, Logout Redirect) and capability (user specific capabilities).

You have to be very careful with exporting users settings and post (Posts & Pages) settings as AAM does not do any additional validation during settings import. AAM assumes that whatever site your are exporting from, is the complete mirror of the site you are importing too. Which means all user IDs, post IDs, category IDs has to match.

Get Development Package with all extensions included for unlimited number of sites

Learn More

Get the latest updates and promos.