You need to be logged in to post in the forum - Log In

An active JCE Pro Subscription is required to post in the forum - Buy a Subscription

Support is currently Offline

Official support hours
Monday to Friday
09:00 - 17:00 Europe/London (BST)

Please create a new Ticket and we will get back to you as soon as we can.

#103599 Problem with image sizes

Posted in ‘Editor’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Latest post by Joyce76 on Thursday, 26 March 2020 09:46 GMT

Joyce76
Hi,
I have a problem with the format of the images on this website: https://triple-group.nl/nl/wat-doen-we/finance
The logos must all be displayed 110px wide.

The images are different in size, but I entered the correct size in the editor. However, he has recently stopped showing it properly in the browser. It seems like something has changed after an update. I also have this problem at: https://www.loonbedrijfroodenburg.nl/nieuws

Can you tell me what's going wrong here?

Attachments

Ryan
Looking at the source code of the module containing the images on this page - https://triple-group.nl/nl/wat-doen-we/finance - they are not all set at 120px wide. I would recommend changing the way you handle this, by inserting the images without dimensions (or with only a width value of 120) and then using css to set the image width for all images in the module. For example, adding the following to your template stylesheet should work:

#sidebar .custom img {
    width: 120px;
}

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

Joyce76
That works fine with this site.

But how would you do that here? https://www.loonbedrijfroodenburg.nl/nieuws
The editor shows the correct format (300x225).
It is shown much larger in the browser. That's not supposed to be?

Attachments

Ryan
Assuming you are referring to the image in the article "natuurvriendelijke oever", it appears that the image is being displayed in the front-end with the full dimensions. Perhaps this is being done by another plugin you have installed on the site?

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

Ryan
Please send me a login - https://www.joomlacontenteditor.net/contact/site-login

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

Ryan
I am getting the same result on your site whether the editor is set to JCE or Tinymce. Although the image dimensions are set to 320 x 225 in the editor, and saved with these values to the database, the image dimensions are reset in the HTML code to the images full width and height.

As the editor is not active when the content is rendered in the front-end, I can only suspect that there is something else on your site that is altering the image dimensions as the code is rendered to the page.

I cannot find a specific plugin that might be doing this, so I think it could be something in your template.

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

Joyce76
I found the problem. Indeed it was in a plugin. "JCH Optimize"
Add Images Attributes was activated, which is what caused the problem.

Thank you for thinking along.

Attachments