Index: _source/plugins/htmldataprocessor/plugin.js
===================================================================
--- _source/plugins/htmldataprocessor/plugin.js (revision 6241)
+++ _source/plugins/htmldataprocessor/plugin.js (revision )
@@ -92,7 +92,14 @@
delete blockLikeTags.pre;
var defaultDataFilterRules =
{
- elements : {},
+ elements : {
+ a : function( element )
+ {
+ var attrs = element.attributes;
+ if ( attrs && attrs[ 'data-cke-saved-name' ] )
+ attrs[ 'class' ] = ( attrs[ 'class' ] || '' ) + ' cke_anchor';
+ }
+ },
attributeNames :
[
// Event attributes (onXYZ) must not be directly set. They can become
@@ -273,7 +280,8 @@
defaultHtmlFilterRules.elements[ i ] = unprotectReadyOnly;
}
- var protectAttributeRegex = /<((?:a|area|img|input)\b[\s\S]*?\s)((href|src|name)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+)))([^>]*)>/gi,
+ var protectElementRegex = /<(a|area|img|input)\b([^>]*)>/,
+ protectAttributeRegex = /\b(href|src|name)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+))/gi,
findSavedSrcRegex = /\sdata-cke-saved-src\s*=/;
var protectElementsRegex = /(?: