Prechádzať zdrojové kódy

Should fix bug when adding editing meta tags inside the head tag see BT#4370

Julio Montoya 12 rokov pred
rodič
commit
e0efd42c62

+ 6 - 4
main/inc/lib/fckeditor/editor/_source/internals/fck.js

@@ -381,10 +381,10 @@ var FCK =
 		var oRegex ;
 		if ( sTags.length > 0 )
 		{
-			oRegex = new RegExp( '<(' + sTags + ')(?!\w|:)', 'gi' ) ;
+			oRegex = new RegExp( '<(' + sTags + ')(?!\w|:)', 'gi' ) ;            
 			html = html.replace( oRegex, '<FCK:$1' ) ;
 
-			oRegex = new RegExp( '<\/(' + sTags + ')>', 'gi' ) ;
+			oRegex = new RegExp( '<\/(' + sTags + ')>', 'gi' ) ;            
 			html = html.replace( oRegex, '<\/FCK:$1>' ) ;
 		}
 
@@ -398,8 +398,10 @@ var FCK =
 		sTags = 'META' ;
 		if ( FCKBrowserInfo.IsIE )
 			sTags += '|HR' ;
-
-		oRegex = new RegExp( '<((' + sTags + ')(?=\\s|>|/)[\\s\\S]*?)/?>', 'gi' ) ;
+        
+        //Fixes bug when editing meta tags see BT#4370
+		//oRegex = new RegExp( '<((' + sTags + ')(?=\\s|>|/)[\\s\\S]*?)/?>', 'gi' ) ;
+        oRegex = new RegExp( '<((' + sTags + ')(?=\s|>)[\s\S]*?)/?>', 'gi' ) ;
 		html = html.replace( oRegex, '<FCK:$1 />' ) ;
 
 		return html ;