Display intro image in Joompla 3 template

1. Open and edit  “_item.php” file in Joomla folder/modules/mod_articles_news/tmpl/_item.php

2. After line 12, add:

$images = json_decode($item->images);

if( $images->image_intro && $params->get(‘image’) ){
 echo ‘<img src=”‘ . $images->image_intro . ‘” alt=”‘ . htmlspecialchars($article->title) . ‘” />’;
 }

3. Save and refesh web page to view result.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s