Hello, I am working on a template somebody else has made. We have a frontpage template that shows articles introtexts & images. Since 3.7 the images are not shown.
if (isset($tag)) {
if(strpos($tag->getAttribute('src'), "http") !== FALSE && !strpos($tag->getAttribute('src'), "www") !== FALSE) {
echo "<img src='" . $tag->getAttribute('src') . "' alt='' />";
} else {
echo "<img src='" . JURI::root() . $tag->getAttribute('src') . "' alt='' />";
}
}
It is a very hacky solution. How to properly access the first image of the article?
Please ask this question on the forum https://forum.joomla.org OR on the mailing list https://groups.google.com/forum/#!forum/joomla-dev-general