Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,221 of 9,224 pages
About the help in other languages
All help pages

Move inline styles into the stylesheet

style="" and <style> in old templates go into your stylesheet, packed with the theme's.

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/help/build-two-ways/examples/migrate/move-styles-out-of-templates.md

On this page

Move inline styles into the stylesheet

Templates without inline CSS, styles cached.

Life cycle: Migrate, example 29 of 34. Worked out on the Fit & Healthy site of Exponential 6.0.15+.

Contents

  1. In the Layouts editor
  2. With templates
  3. Which to choose
  4. Check

In the Layouts editor

  1. Blocks with typed styles in HTML snippets: replace them too.

With templates

  1. Replace each style="" by a class; add the rules to mysite.css; list the file in your extension's design.ini ([StylesheetSettings] FrontendCSSFileList[]=mysite.css).

Which to choose

One stylesheet, no inline CSS.

Check

  • No style= left in your templates.

Become an Exponential Partner

Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x