Creative Exchange exports files with broken asset URLs

  • Browsers might not display styles and scripts correctly, when exporting an SXA website (theme, page) with the Creative Exchange module. The module generates the static files, which were processed by the Assert Optimizer, however, the links to the optimized CSS and JavaScript assets point to files that are not in the .zip package.

    For example, a .zip package contains the following files

    /sitecore/media/Base Themes/Core Libraries/scripts/optimized-min.js
    /sitecore/media/Base Themes/Core Libraries/styles/optimized-min.css

    but links to concatenated assets include unwanted numbers and hyphens:

    -/media/Base-Themes/Core-Libraries/scripts/optimized-min-1.js
    -/media/Base-Themes/Core-Libraries/styles/optimized-min-2.css
  • To resolve the issue, consider one of the following options:

    • Disable the Asset Optimizer manually as specified in the official Documentation as follows:
      In the Content Editor, navigate to
      • /sitecore/system/Settings/Foundation/Experience Accelerator/Theming/Optimiser/Scripts
      • /sitecore/system/Settings/Foundation/Experience Accelerator/Theming/Optimiser/Styles
      and set the mode from "Concatenate And Minify" to "Disabled".
    • Open the \App_Config\Modules\SXA\Foundation\Sitecore.XA.Foundation.Theming.config file and set the XA.Foundation.Theming.AssetsOptimizationSwitch.Enabled setting value to "true".

Applies to:

SXA 1.8 Initial Release - 1.8 Update-1

SXA 1.9 Initial Release

April 14, 2020
April 14, 2020

Reference number:

301730

Keywords: 

  • SXA