Change background image on page refresh

Hi! I don’t know how to do that, I tried in code embed and custom code with codes of stackoverflow


Here is my site Read-Only: LINK
(how to share your site Read-Only link)

@Miriam_Valdivia
Is your intention to randomly serve a background image based on page load?

yes! I need help I don’t how

@Miriam_Valdivia

  1. create a CMS Collection called ‘Random BG’
  2. Create class ‘BG layer’, z=0, position= absolute as a child where you want the BG to appear / should be sibling to main content. Your Main content should be z=1
  3. Inasert CMS Collection into ‘Random BG’
  4. Set rule = random order image
  5. Set Limit = 1 image
1 Like