Bug #88369

Ckeditor: customs plugins are not refreshed because of browser cache

Added by DANIEL Rémy over 1 year ago. Updated 10 months ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2019-05-16
Due date:
% Done:

100%

TYPO3 Version:
8
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

When a custom CKEditor plugin is modified, if it was in the browser cache before, the old version can be loaded.

To prevent this, CKEDITOR.timestamp can be used to add a "?t=" parameter to the url of plugins JS files.
CKEDITOR.timestamp has a default value in ckeditor.js and changes with every ckeditor releases.
On TYPO3 8.7 with ckeditor 4.11.1, CKEDITOR.timestamp is "IA8E" (it is not a real timestamp).

TYPO3 should override CKEDITOR.timestamp with a custom hash.
In a ideal scenario, this hash should be recalculated every time a custom plugin is edited.
But it is not very possible.

So I suggest that this hash can be the result of a MD5 of ckeditor configuration.
Every time the configuration is changed (like when adding an external plugin), the hash will change, and the browser cache will not serve an old version of a plugin.


Related issues

Related to TYPO3 Core - Bug #83626: CKEditor styling: CSS file changes are not visible because of cache handling New 2018-01-21

Associated revisions

Revision 9e819f9e (diff)
Added by DANIEL Rémy over 1 year ago

[BUGFIX] Refresh browser cache when ckeditor config or plugins changes

CKEDITOR.timestamp now contains also a hash of the configuration.
This is appended to uri when CKeditor loads resources.

This mitigates issues with browser caching when CKeditor plugins are
updated.

Resolves: #88369
Releases: master,9.5,8.7

Change-Id: I9f4a8f611683db93c47b62d22871eac23f3a8819
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60819
Tested-by: TYPO3com <>
Tested-by: Frank Naegler <>
Tested-by: Andreas Fernandez <>
Reviewed-by: Benni Mack <>
Reviewed-by: Frank Naegler <>
Reviewed-by: Andreas Fernandez <>

Revision 70da4de7 (diff)
Added by DANIEL Rémy over 1 year ago

[BUGFIX] Refresh browser cache when ckeditor config or plugins changes

CKEDITOR.timestamp now contains also a hash of the configuration.
This is appended to uri when CKeditor loads resources.

This mitigates issues with browser caching when CKeditor plugins are
updated.

Resolves: #88369
Releases: master,9.5,8.7

Change-Id: I9f4a8f611683db93c47b62d22871eac23f3a8819
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60853
Tested-by: TYPO3com <>
Tested-by: Andreas Fernandez <>
Reviewed-by: Andreas Fernandez <>

Revision 8d5c45d2 (diff)
Added by DANIEL Rémy over 1 year ago

[BUGFIX] Refresh browser cache when ckeditor config or plugins changes

CKEDITOR.timestamp now contains also a hash of the configuration.
This is appended to uri when CKeditor loads resources.

This mitigates issues with browser caching when CKeditor plugins are
updated.

Resolves: #88369
Releases: master,9.5,8.7

Change-Id: I9f4a8f611683db93c47b62d22871eac23f3a8819
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60854
Tested-by: TYPO3com <>
Tested-by: Andreas Fernandez <>
Reviewed-by: Andreas Fernandez <>

History

#1 Updated by DANIEL Rémy over 1 year ago

  • Related to Bug #83626: CKEditor styling: CSS file changes are not visible because of cache handling added

#2 Updated by Gerrit Code Review over 1 year ago

  • Status changed from New to Under Review

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60819

#3 Updated by Gerrit Code Review over 1 year ago

Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60853

#4 Updated by Gerrit Code Review over 1 year ago

Patch set 1 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60854

#5 Updated by DANIEL Rémy over 1 year ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#6 Updated by Benni Mack 10 months ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF