I have some global images that I use throughout the site. I want the url to be the same even when switching between languages.
<img src="<?= $site->url() ?>/assets/media/content/image.jpg">
When I switch language, the above results in a broken image:
With some testing I noticed that $site->url(’’) would fix the problem, is this the correct way to do it?
<img src="<?= $site->url('') ?>/assets/media/content/image.jpg">