Opened 14 years ago

Closed 12 years ago

Last modified 10 years ago

#5566 closed Bug (fixed)

Smart tags not dealt with by pastefromword

Reported by: navnorth Owned by:
Priority: Normal Milestone:
Component: Plugin : Paste from Word Version:
Keywords: Cc:

Description

Smart tags are not dealt with in any way by the pastefromword plugin.

One of our users attempted to paste content from a Word Document into CKEditor. The content contained the following line.

<st1:stockticker w:st="on"><u>JOB</u></st1:stockticker><u>TITLE</u>

In this case, the smart tag was inserted incorrectly in the Word Document, but that is true for many documents created with automatic smart tagging enabled.

Smart tags should be removed in the same way that other Word-specific tags are removed, while preserving any content between the tags. Leaving smart tags intact causes display issues if the content from a wysiwyg is later displayed as html.

For our system, I added the following lines to the default.js for the pastefromword plugin.

h=h.replace(/<st1[^>]*>/g,'');
h=h.replace(/<\/st1[^>]*>/g,'');

This removes all <st1> tags, while leaving contained content alone.

Change History (2)

comment:1 Changed 12 years ago by Jakub Ś

Resolution: fixed
Status: newclosed

It seems that in latest CKEditor 3.6.3 smart tags are stripped.

NOTE: Seems that smart tags were dropped and are no longer available in MS 2010.

comment:2 Changed 10 years ago by Frederico Caldeira Knabben

Component: Core : PastingPlugin : Paste from Word
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