I've tried to place my override code file to /templates/TEMPLATE/html/layouts/joomla/html/ and to /templates/TEMPLATE/html/ but had no luck in Joomla! picking that up and instead it goes on with its stock image layout.
The funny thing is, when I include the image layout directly with something like the code snippet below then my override file gets properly included instead of the stock layout:
Code: Select all
<?php echo Joomla\CMS\Layout\LayoutHelper::render('joomla.html.image', array('src' => $itemImagePath, 'alt' => $itemImageAlt)); ?>
Code: Select all
<?php echo Joomla\CMS\HTML\HTMLHelper::image($itemImagePath, $itemImageAlt); ?>
https://docs.joomla.org/J3.x:Layout_Overrides_in_Joomla
P.S. My Joomla! version is 3.10.12