Usage

Copying a Theme

When to copy a theme

Copying a theme gives you a complete duplicate to experiment with, or a starting point for a child of a theme you do not want to modify directly. The copy is a full directory copy, so it includes assets, configuration and every other file, not only the .phtml templates.

Copying

  1. Open the editor and select the theme to duplicate in Theme:.
  2. Click Copy Theme… in the toolbar.
  3. In the Copy Theme dialog, Source theme shows the selected theme. Type a New theme name using only letters, numbers, _ and - (up to 128 characters). This becomes the directory name under themes/.
  4. Click Copy.

The module then:

  • creates themes/<new-name>/ and copies every file and directory from the source, skipping symbolic links;
  • updates the name entry in the new theme's config/theme.ini (or theme.ini in the theme root) to a title-case version of the directory name, so my-theme-copy becomes My Theme Copy;
  • records an initial revision for every .phtml file under the new theme's view/ directory, with the summary Copied from theme: <source>;
  • reloads the editor with the new theme selected.

The new theme is available for selection on each site's Theme page like any other installed theme.

Requirements and limits

  • The themes/ directory must be writable by the web server user, otherwise the copy fails with Failed to create directory.
  • The target name must not already exist in themes/.
  • Large themes can take a moment; the dialog shows Copying… this may take a moment. until it finishes.
  • The module never deletes a theme. Remove an unwanted copy on the server.
Log in for Support