Solved

Use images with liquid? Is it possible?

  • 31 March 2023
  • 1 reply
  • 339 views

I tried with an image block and placing the liquid code in the url bar such as {{customer.company_logo}}, when i try to save that it seems to be stripping out the code and doesnt save it.

 

Also I tried to do it with custom html in this way “<img src=”customer.company_logo”>, this just display the tiny icon that shows when an image doesnt exist.

 

I am 100% sure that the attribute is only containing the image url, so this is not the issue. 

 

Please help.

icon

Best answer by Felix 31 March 2023, 12:15

View original

1 reply

Userlevel 4

Hey Fkkm,

in order for an dynamic image url to work, you have to activate “Dynamic image”. You can place there your Liquid code. Make also sure to upload and select a fallback image, in case the image url is not given:

In your custom html, you forgot to add the mustaches in order to indicate that you are referring to liquid code. Try <img src=”{{customer.company_logo}}”>

 

Hope that helps,

Felix 😉

Reply