PR-4.3-dev Pending

User tests: Successful: Unsuccessful:

avatar hans2103
hans2103
17 May 2023

Pull Request for no issue

Summary of Changes

This PR will replace the hard coded <img src="" alt=""/> by HTMLHelper::_('image',$src,$alt,$data) for the default output of module mod_bannsers

The HTMLHelper::_('image'will render the JLayout joomla.html.image

return LayoutHelper::render('joomla.html.image', $attribs);

In cases a Frontend Developer created a template override of this JLayout, the changed can profit too.
( in my case... I've created a template override to be able to use imagekit.io for image rendering... others might create an override to use Cloudinary)

Testing Instructions

  • Joomla with sample data
  • Make sure the mod_banners is assigned to a menu item and set to show images. Change module config if it does not.
  • Apply the patch and refresh the page where mod_banners is used

Before and after should look the same... only the way the code is generated changed.

Actual result BEFORE applying this Pull Request

  • images are shown

Expected result AFTER applying this Pull Request

  • images are shown the same way as before

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

avatar joomla-cms-bot joomla-cms-bot - change - 17 May 2023
Category Modules Front End
avatar hans2103 hans2103 - open - 17 May 2023
avatar hans2103 hans2103 - change - 17 May 2023
Status New Pending
avatar hans2103 hans2103 - change - 17 May 2023
Labels Added: PR-4.3-dev
avatar brianteeman
brianteeman - comment - 17 May 2023

Should it not be
LayoutHelper::render('joomla.html.image',

?

avatar hans2103
hans2103 - comment - 17 May 2023

After discussion on Joom.la/chat in channel PB Buq Squad we've concluded that the JLayout should be used instead of HTMLHelper and it should be a PR on 5.0.
Therefor I close this PR and create a proper new one

avatar hans2103 hans2103 - close - 17 May 2023
avatar hans2103 hans2103 - change - 17 May 2023
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2023-05-17 10:17:11
Closed_By hans2103

Add a Comment

Login with GitHub to post a comment