Project

General

Profile

Actions

Bug #20316

closed

image scaling fails when saving

Added by Sebastian Meyer about 15 years ago. Updated over 14 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2009-04-16
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

When inserting a new magic image in RTE it is correctly downscaled to the max dimensions defined in pageTSconfig. At this moment a copy of the image (with the new dimenions) is created in the uploads folder and linked to in the RTE. Everything okay so far.
But when I hit the "save" button in RTE, another copy of the image is created in the uploads folder, which is NOT scaled (and replaces the old one). As a result, the much too big image is shown in the frontend (and in RTE after re-opening the content element, too).
When manually scaling an already inserted image in the RTE, nothing happens. The RTE shows the scaled image, but no copy is created in uploads folder and so there are pretty much no changes at all after saving.

So the problem seems to be the saving process in RTE, which does not render the scaled copies of inserted images correctly. I don't know if this is a RTE or a DAM problem, but I think it is related to RTE because it occurs on saving a content element in RTE.

I am using TYPO3 4.2.6 with DAM 1.1.1, both updated from previous versions 4.1.10 and 1.0.100 (from svn). There's no local copy of rtehtmlarea installed. Since updating I have a problem with the image scaling in RTE. I already reviewed the DAM documentation and followed the instructions there after updating.
(issue imported from #M10912)

Actions #1

Updated by Sebastian Meyer almost 15 years ago

I could solve this issue.

What I learned:
- Image scaling is based on the width and height attributes of the image tags in RTE. (The values of these attributes are considered as target size for the scaled image.)
- These attributes were disallowed in my RTE configuration.
- Prior to version 4.2.* of TYPO3 this was not a problem, because image scaling took place before disallowed attributes were removed.
- Since version 4.2.* of TYPO3 this has been changed: now the removal of disallowed attributes occurs prior to the image scaling, which therefor fails because of the lack of width and height attributes.

After allowing these attributes, image scaling works perfectly again.

Actions #2

Updated by samrat chakraborty over 14 years ago

Can u tell the exact configurations for image scalling.

Actions #3

Updated by Stanislas Rolland over 14 years ago

That's right. If you use the Extension Manager to enable images in the RTE, and if you do not disallow attributes on the img tag in your Page TSConfig RTE proc options, then the images will be scaled correctly. Note that re-scaling occurs on the way to the database.

Actions

Also available in: Atom PDF