Opened 14 years ago

Last modified 11 years ago

#5294 confirmed New Feature

Handling textareas within CKeditor

Reported by: QQQ Owned by:
Priority: Normal Milestone:
Component: Core : Output Data Version: 3.0
Keywords: Cc:


<textareas> are being handled like normal HTML tags, when they should be getting the same treatment as <pre> tags.

I've done a quick look and from what I see, the offending file would be fragment.js: -Line 152: Original: "&& != 'pre'" Possible replacement: " && != 'pre' && != 'textarea'"

-Line 191: Original: "else if ( tagName == 'pre' )"

Possible replacement: "else if ( tagName == 'pre'
tagName == 'textarea' )"

-Line 332: Original: "if ( == 'pre' )"

Possible replacement: "if ( == 'pre' == 'textarea' )"

That should theoretically fix it. I haven't worked much with it, so this is all untested, but it'd be nice if someone who has more of an idea how to work this could make a proper patch.

Attachments (1)

fragment_new.js (13.8 KB) - added by QQQ 14 years ago.
my applied changes

Download all attachments as: .zip

Change History (8)

Changed 14 years ago by QQQ

Attachment: fragment_new.js added

my applied changes

comment:1 Changed 14 years ago by QQQ

is anyone going to be doing anything about this?

comment:2 Changed 14 years ago by Frederico Caldeira Knabben

Keywords: HasPatch added; textarea spacing br pre removed

comment:3 Changed 14 years ago by Frederico Caldeira Knabben

Milestone: CKEditor 3.x

Milestone CKEditor 3.x deleted

comment:4 Changed 13 years ago by Wiktor Walc

Version: SVN (CKEditor) - OLD3.0

comment:5 Changed 12 years ago by Jakub Ś

Keywords: HasPatch removed
Status: newconfirmed

User means that contents of textarea element should not be changed by the editor, just like a <pre> tag.

NOTE: I don't think that patch is valid.

comment:6 Changed 11 years ago by Jakub Ś

Problem can be still reproduced in CKEditor 4.x (v4).

#9995 was marked as duplicate.

Here is pull request from #9995:

Version 1, edited 11 years ago by Jakub Ś (previous) (next) (diff)

comment:7 Changed 11 years ago by Piotrek Koszuliński

I reopened #9995 because that was a separate issue related to processing, not parsing.

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