Welcome, Guest
Username: Password: Remember me

TOPIC: Intro image not shown in new published articles

Intro image not shown in new published articles 10 years 3 weeks ago #497

Hi, We need urgent help!
All new items are published without intro image in JO Responsive scroller.
If you go directly to the link from the menu: STIRI - Stiri Regiunea Centru you will see the intro image.
I need urgent help because the deadline for the site. Thanks for understanding!
Please use sorinmurar at gmail dot com for response. Can not receive mail from you to This email address is being protected from spambots. You need JavaScript enabled to view it. Excuse my english :-)
Attachments:
Last Edit: 10 years 3 weeks ago by Anca Cadan.
The administrator has disabled public write access.

Intro image not shown in new published articles 10 years 3 weeks ago #498

  • Super User
  • Super User's Avatar
  • OFFLINE
  • Administrator
  • Posts: 3519
  • Thank you received: 278
  • Karma: 65
Hi
Find and open file: modules/mod_jo_responsive_scroller_articles/helper.php
Go to line 146 and added code bellow
if (!empty($images->image_intro)){
$item->imageMedium = JURI::root().$images->image_intro;
$resizeObj = new resize($item->imageMedium);
$resizeObj -> resizeImage($params->get('thumbwidth'), $params->get('thumbheight'), 'crop');
$resizeObj -> saveImage($destination.'/mod_jo_responsive_scroller_articles/'.'p'.$params->get('thumbwidth').'x'.$params->get('thumbheight').'/'.md5("Image".$item->id).'_M.jpg', 100);
$item->image_thumb = JURI::root().'images/mod_jo_responsive_scroller_articles/'.'p'.$params->get('thumbwidth').'x'.$params->get('thumbheight').'/'.md5("Image".$item->id).'_M.jpg';

}
You can see
.....
$images = json_decode($item->images);

if (!empty($images->image_intro)){
$item->imageMedium = JURI::root().$images->image_intro;
$resizeObj = new resize($item->imageMedium);
$resizeObj -> resizeImage($params->get('thumbwidth'), $params->get('thumbheight'), 'crop');
$resizeObj -> saveImage($destination.'/mod_jo_responsive_scroller_articles/'.'p'.$params->get('thumbwidth').'x'.$params->get('thumbheight').'/'.md5("Image".$item->id).'_M.jpg', 100);
$item->image_thumb = JURI::root().'images/mod_jo_responsive_scroller_articles/'.'p'.$params->get('thumbwidth').'x'.$params->get('thumbheight').'/'.md5("Image".$item->id).'_M.jpg';
}elseif (!empty($images->image_fulltext)){
$item->imageMedium = JURI::root().$images->image_fulltext;
$resizeObj = new resize($item->imageMedium);
.....
Or can you send me joomla administrator via contact form? So i can help you
Best regards
Bach Pham
Last Edit: 10 years 3 weeks ago by Super User.
The administrator has disabled public write access.

Intro image not shown in new published articles 10 years 3 weeks ago #499

After adding the code I received an error page:


”Parse error: syntax error, unexpected '?>', expecting function (T_FUNCTION) in /home/europenx/public_html/1/modules/mod_jo_responsive_scroller_articles/helper.php on line 245”
The administrator has disabled public write access.

Intro image not shown in new published articles 10 years 3 weeks ago #500

  • Super User
  • Super User's Avatar
  • OFFLINE
  • Administrator
  • Posts: 3519
  • Thank you received: 278
  • Karma: 65
Hi :)
You have misunderstood my code. We have changed it for you and now it work fine. Can you see it
And can you see the code we have added in file in line 148->154
Thank you for using our products
Best regards
Bach Pham
The administrator has disabled public write access.
Time to create page: 0.166 seconds