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.

#106215 [BUG] Images need both width and height in Imager manager, otherwise they are displayed as full

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 Ryan on Tuesday, 05 January 2021 13:07 GMT

GameWorld
The image manager , in Image Dimensions is not working.

I used 12 images with dimensions of around 800-1200 pixels each.
I made an article and for each image, in the Image Manager inside the article, I put only the height. For example 300 pixels. I saved and after some hours I saw the article live and realized that images do not resize in 300 pixels (with the corresponding height) as they should. Instead, they are displayed as full size!



I had to set both width and height to 300 so that my images will work! As a result, I uploaded an article, which on the editor looked normal (images looking to have 300 pixels size)



This needs to be fixed so that putting only width or only height should display the image normally.
Also this was tested in Incognito browser.

Attachments

Ryan
The images are displayed as full size because of some css rules in your template, for example if the image is an intro image in an article, your template is overrding the width value you have added.

Ryan Demmer

Lead Developer / CEO / CTO

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

GameWorld
And where is that? The only custom code I see in the template is in the Before /head for Google Ads.

Also I can't reply with the code in this topic.

Ryan
The css rule that may be causing the issue is on line 4432 of templates/cepon/css/custom.css

.article-intro img, .article-content img {
    display: block;
    width: auto;
    overflow: hidden;
}
by setting both the width and height, or just the height, of an image, you can override this css rule style.

Ryan Demmer

Lead Developer / CEO / CTO

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

GameWorld
Sorry but please can you explain it in full detail? Like

Code.
[ ]

Replace
[ ]

So that I can change the code as you suggest and don't do any mistake.

Thank you and happy new year.

Ryan
Replace

.article-intro img, .article-content img {
    display: block;
    width: auto;
    overflow: hidden;
}
with

.article-intro img, .article-content img {
    display: block;
    overflow: hidden;
}

Ryan Demmer

Lead Developer / CEO / CTO

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

GameWorld
Site was broken after this.

[video]

Attachments

Ryan
If you are not confident in making changes to css on your site, then I suggest you do as I suggested above and insert images either with both the width and height value set, or just the height value (leave the width value blank)

Ryan Demmer

Lead Developer / CEO / CTO

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