cancel
Showing results for 
Search instead for 
Did you mean: 

what is the right syntax for {{media url...}}?

what is the right syntax for {{media url...}}?

I have banner jpgs loaded into public_html/update/pub/images folder which do not show on the frontend [Home Page]

 

For example:

{{media url="update/pub/images/affiliates.jpg"}} 

when I go to http://domain.com/update/pub/images/affiliates.jpg, I see the image.  

 

Do the images have to be in the wysiwyg folder?

 

Can someone PLEASE tell me the correct syntax.  Thanks for your attention.

2 REPLIES

Re: what is the right syntax for {{media url...}}?

Hi,

 

You can access media url like - {{media url=test/logo.png}} 

now you read from media folder pub/media example

<p><img src="{{media url=test/logo.png}}" alt="" /></p>


after you create your folder test inside pub/media and add  logo.svg the result is

<img alt="" src="http://domain.com/pub/media/test/logo.png">

Hope this will help you.

Re: what is the right syntax for {{media url...}}?

Thanks for your response.  Unfortunately, it needs to be in the wysiwyg directory.

background: url('{{media url="wysiwyg/affiliates.jpg"}}')