Skip to main content

Migrating to version 6.x

Events Manager 6 replaced the plugin's front end: calendars, lists, search and booking forms got new HTML, new CSS and new default formats. A site upgraded from version 5 keeps its own formats and template overrides, so nothing is overwritten without your say, but the new CSS can clash with customizations made for the old markup.

This page is for sites that were on version 5 and have customized how events look, through the format settings or by overriding template files. It explains the tools version 6 gives you for moving across, all of which are still in the current release. If your site was first installed on version 6 or later, none of this applies. For the changes in version 7, see Upgrading to Events Manager 7.

Before you start

Back up your site files and your database before a major upgrade. The formats and settings discussed here are stored in the wp_options table.

What the upgrade changes​

AreaWhat happens on upgrade from version 5
Format settingsKept as they are. You are offered a preview of the new defaults and a one-click migration, described below.
Template files overridden in your themeStill used. Many of the plugin's own templates changed, so compare yours with the new ones. See Template files.
CSSThe new styles load. They can be reduced or switched off. See CSS.
Database (6.1)New tables and a change to how booked tickets are stored. See Database changes in 6.1.

CSS​

If your theme or custom CSS restyled the old templates, start by turning down the new styles. They are controlled in Events then Settings then General then Styling Options (Advanced).

Styling can be switched off entirely, or one component at a time.

OptionWhat it does
Enable All Styling?Set to No and Events Manager styles nothing on the front end. Its wrapping elements lose the em class that the plugin's layout rules hang on, including the structure of calendars and lists. Most sites should leave this on.
Enable Theme Styling?The stricter layer, applied through the pixelbones class. It normalizes fonts, sizes, spacing, form fields and buttons inside Events Manager's components so they look the same in every theme. This is the layer most likely to conflict with a theme. Set it to No to let your theme style those elements.
Default font family, Base font size, Base line height, Base font weightEach can be Default plugin setting or Inherit your theme settings. On a site upgraded from version 5 they start on your theme's settings.
Individual ComponentsOne select for each part of the plugin: the calendar, the list pages, single pages, search forms, booking forms, the My Bookings page and the admin pages. Each can be Enabled, Disabled or Basic Only, which keeps the structural rules and drops the strict ones.

The options get more specific as you go down the section. Try the broad ones first, and if the result isn't what you wanted, set them back. Nothing is lost by switching them.

The plugin's look is driven by CSS variables, so small changes often need one rule and no settings at all. For example, in Appearance then Customize then Additional CSS:

body .em.pixelbones { --font-family: arial; --font-size: 14px; --font-weight: normal; --line-height: 16px; }

Formats​

The formats on the Formatting tab are stored in your database, and the upgrade does not replace them. In version 6 every format also exists as a file in the plugin's templates/formats/ folder. Those files are what a new install uses, and what your site uses for any format you choose not to override.

The migration notice​

After the upgrade from version 5, a notice headed Welcome to Events Manager v6! appears at the top of Events then Settings. It stays until you dismiss it and offers three choices:

ButtonWhat it does
Enable Preview ModeShows you, and only you as an administrator, the site with the new default formats and fonts. Visitors still see your saved formats. You can keep editing and saving settings while it is on, and nothing saved is overwritten. Disable Preview Mode turns it off.
Migrate FormatsReplaces all your saved formats with the new defaults and turns Advanced Mode off. Your old formats are kept so the step can be undone.
DismissKeeps everything as it is and removes the notice. You can still adopt the new formats one at a time, as described below.

After Migrate Formats the notice changes to offer Undo Migration, which puts your old formats back, and Dismiss.

caution

Clicking Dismiss after a migration deletes the stored copy of your old formats. From then on the migration can't be undone, so check the front of your site first.

Advanced Mode​

The Advanced Mode section at the top of Events then Settings then Formatting decides where formats come from. It has three states:

StateWhere formats come from
Advanced Mode disabledThe plugin's template files. The format boxes are hidden, and improvements to the default formats reach your site with each update. This is the state of a new install.
Advanced Mode enabledYour choice, group by group. Each group of formats gets an Override Default Formats? switch. Set to Yes, the group uses the formats saved in your settings. Set to No, it uses the template files.
Super Advanced Mode enabledYour saved settings, for every format, as in version 5. A site upgraded from version 5 starts here.

Advanced Mode on the Formatting tab. The heading shows whether it is enabled.

The buttons change nothing until you click Save Changes.

For most sites coming from version 5, plain Advanced Mode is the middle ground: disable Super Advanced Mode, then switch Override Default Formats? on only for the groups you have customized. Your saved formats are never deleted by these switches. Turn an override off and the format is kept in the database, and it comes back when you turn the override on again.

Start from a new default format​

To make a small change to one of the new formats, such as adding a line of text to each event in a list, load the default into the setting and edit it there.

  1. Make sure Advanced Mode is enabled and the group's Override Default Formats? is Yes.

  2. Next to the format's text area, click the reset icon, which shows Reset to default value? when you hover over it. The box is filled with the format from the plugin's template file.

  3. Edit the format and click Save Changes.

Template files​

Overriding template files works as it did in version 5, with one addition: besides your theme, overrides can now live in wp-content/plugin-templates/events-manager/ (and wp-content/plugin-templates/events-manager-pro/ for Pro templates), where a theme update can't remove them. See Using Template Files.

Many of the plugin's templates were rewritten for version 6. Compare your overrides with the new files, and where you keep your own, copy the class names of the new markup so the plugin's JavaScript can find the elements it works with.

The calendar changed most. Its templates moved to a calendar folder inside templates. If your theme overrides calendar-full.php or calendar-small.php, Events Manager still uses your file in place of the new templates.

Keeping the version 5 templates​

As a last resort, you can copy the whole templates folder from a version 5 copy of the plugin into wp-content/plugin-templates/events-manager/. The site then renders with the version 5 templates. This buys time on a heavily customized site, but features that depend on the new markup won't work, so treat it as a first step and not a destination.

Database changes in 6.1​

Version 6.1 changed how bookings are stored. The upgrade:

  • adds the tables wp_em_bookings_meta and wp_em_tickets_bookings_meta
  • copies data from the booking_meta column of wp_em_bookings into the new tables, deleting nothing
  • gives every booking a unique booking_uuid
  • rewrites wp_em_tickets_bookings so that each row is one space, each with its own ticket_uuid

The last step is the one that can't be reversed by installing an older version. Before 6.1 a booking of three spaces of one ticket was one row, and now it is three.

Events Manager Pro 3.0 builds on this: attendee details that used to be stored with the booking are moved to wp_em_tickets_bookings_meta, so each booked space carries its own attendee information. That is what makes per-ticket features such as QR check-in possible.

Events Manager Pro older than 3.0​

If Events Manager finds a Pro version older than 3.0, administrators see the notice Due to some inevitable changes to some code in Events Manager 6.1, it is necessary to use Pro 3.0 or later, this change affects attendee forms. The fix is to update Pro. Events Manager 7.5 recommends Pro 3.9 or later, and an old Pro misses years of fixes.

If you can't update Pro yet, attendee forms in Pro 2.x can be kept working for new bookings with a one-line change. In events-manager-pro/add-ons/bookings-form/attendee-forms.php, around line 318, find:

if( $EM_Form->get_post(false, $EM_Ticket_Booking->ticket_id, $i) ){

and change it to:

if( $EM_Form->get_post(false, $EM_Ticket_Booking->ticket_id, $EM_Ticket_Booking->ticket_uuid) ){

Then add this to wp-config.php to remove the notice:

wp-config.php
define( 'EMP_3_FIXED', true );

A plugin update overwrites the edit, so treat it as a stopgap.

Going back to version 5​

Older versions of the plugin are listed at the bottom of the Advanced View on WordPress.org. Restoring your backup is the reliable way back. Installing version 5 over an upgraded database works for the format and template changes, but not for bookings changed by the 6.1 upgrade, so don't edit existing bookings while on the old version.

If you do go back and later upgrade again, Events Manager needs to be told to run its upgrade again, or data added in the meantime is not migrated. The installed version is stored in the dbem_version option (em_pro_version for Pro). Set them to a version 5 number such as 5.9999, and 2.9999 for Pro, before upgrading.

Troubleshooting​

My event lists or calendar look broken after upgrading

Your saved formats or template overrides were written for the old markup, and the new CSS is styling them. Either adopt the new formats (try Enable Preview Mode first) or reduce the styling for that component under Individual Components.

Fonts or buttons inside events don't match my theme

Set the four font options in Styling Options (Advanced) to Inherit your theme settings, or set Enable Theme Styling? to No.

I dismissed the notice and want the new formats after all

Disable Advanced Mode on the Formatting tab and save. The site then uses the plugin's default formats, and your old ones stay saved in case you turn it back on.