Opened 9 years ago

Last modified 7 years ago

#13723 confirmed Bug

forceSimpleAmpersand is not working as expected.

Reported by: John Jackson Owned by:
Priority: Normal Milestone:
Component: General Version: 3.0
Keywords: Cc:

Description

Steps to reproduce

  1. Create editor instance with forceSimpleAmpersand = true.
  2. Click the toolbar menu for link.
  3. Add a link 'www.example.com?foo=bar&a=b'.
  4. View source - link now written as 'www.example.com?foo=bar&a=b'.

Expected result

Link should be 'www.example.com?foo=bar&a=b'.

Actual result

Link is 'www.example.com?foo=bar&a=b'.

Other details (browser, OS, CKEditor version, installed plugins)

Chrome 45 on Windows 7, CK Editor version 4.5.3.

This may relate to this commit: https://github.com/ckeditor/ckeditor-dev/commit/7752ceeb7954c36c573c274753c9bb01c7932f7c or possible commits around this that work on similar issues?

Change History (3)

comment:1 Changed 9 years ago by Jakub Ś

Keywords: forceSimpleAmpersand ampersand removed
Status: newconfirmed
Version: 4.5.33.0

I have been able to reproduce this issue in any browser starting from CKEditor 3.0.

Whether I was pasting link into source mode or using Ling dialog, the ampersand was always encoded (getData or switching to source produce & despite config setting)

comment:2 Changed 7 years ago by Jakub Ś

#16802 was marked as duplicate.

comment:3 Changed 7 years ago by Oliver Jusinger

Fix: call htmlEncodeAttr before forceSimpleAmpersand in htmlwriter/plugin.js

Diff:

181a182
> 				attValue = CKEDITOR.tools.htmlEncodeAttr( attValue );
184d184
< 				attValue = CKEDITOR.tools.htmlEncodeAttr( attValue );
Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy