Shopify themes, liquid, logos, and UX
Hey hello,
Can anybody help me with some code to create a gradient background for my webshop, without it effecting the background of the menu's and product grid items?
If i use this code :
{% if template contains 'index' or template contains 'product' %}
<style>
body{background-image: linear-gradient(to right top, #fff4d9, #fff2e3, #fff3f0, #fff6fb, #fffaff, #fefcff, #fefeff, #ffffff, #ffffff, #ffffff, #ffffff, #ffffff);}
</style>
{% endif %}
via https://mycolor.space/
and put it above </head> in the theme.liquid file it works. But only if i put the background colour on transparant in the editor. But if i do that the mega menu and the background of the products in grids become transparant too. Is there a way to use this code and that it works only for the background of the pages? And also is there a way to put the gradient behind all the pages instead of just home and product?
Anybody having a solution for this? Or another code solution?
Thnkszz
Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025