This guide helps you add visuals such as images to your pages using a CSS file and access and display the image through its relative path.
This guide demonstrates using CSS at the code level. The ability to add CSS files using the Instance Admin is under development.
To follow the steps in this tutorial, you should be familiar with the required directory structure for your codebase. In addition, you must understand the concepts of pages, layouts, and assets. Please visit the following resources should you need a refresher:
Adding visuals to your pages using a CSS file is a three-step process:
If you are starting from scratch (without having created the codebase), create an
If you have already created the codebase, you can skip this step and locate your
Put an image in the images directory (e.g.
In the
Here, in a static CSS file, you can't use the
On your computer, the CSS file is in the
This directory structure corresponds to the directory structure on the CDN, so the relative path works the same way on your Instance.
Didn't quite find what you are looking for or have feedback on how we can make the content better then we would love to hear from you. Please provide us feedback and we will get back to you shortly.