Changeset 908
- Timestamp:
- 2007-09-29 00:17:02 (14 months ago)
- Location:
- FCKeditor/trunk
- Files:
-
- 2 modified
-
editor/dialog/fck_paste.html (modified) (3 diffs)
-
_whatsnew.html (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
FCKeditor/trunk/editor/dialog/fck_paste.html
r840 r908 51 51 oFrame.style.display = '' ; 52 52 53 // Avoid errors if the pasted content has any script that fails: #389 54 var oDoc = oFrame.contentWindow.document ; 55 oDoc.open() ; 56 oDoc.write('<html><head><script>window.onerror = function() { return true ; };<\/script><\/head><body><\/body><\/html>') ; 57 oDoc.close() ; 58 53 59 if ( oFrame.contentDocument ) 54 60 oFrame.contentDocument.designMode = 'on' ; 55 61 else 56 62 oFrame.contentWindow.document.body.contentEditable = true ; 63 64 // Set the focus on the pasting area 65 oFrame.contentWindow.focus(); 57 66 } 58 67 else … … 223 232 224 233 // Remove comments [SF BUG-1481861]. 225 html = html.replace(/<\!--.* -->/g, '' ) ;234 html = html.replace(/<\!--.*?-->/g, '' ) ; 226 235 227 236 html = html.replace( /<(U|I|STRIKE)> <\/\1>/g, ' ' ) ; … … 231 240 // Remove "display:none" tags. 232 241 html = html.replace( /<(\w+)[^>]*\sstyle="[^"]*DISPLAY\s?:\s?none(.*?)<\/\1>/ig, '' ) ; 242 243 // Remove language tags 244 html = html.replace( /<(\w[^>]*) language=([^ |>]*)([^>]*)/gi, "<$1$3") ; 245 246 // Remove onmouseover and onmouseout events (from MS Word comments effect) 247 html = html.replace( /<(\w[^>]*) onmouseover="([^\"]*)"([^>]*)/gi, "<$1$3") ; 248 html = html.replace( /<(\w[^>]*) onmouseout="([^\"]*)"([^>]*)/gi, "<$1$3") ; 233 249 234 250 if ( FCKConfig.CleanWordKeepsStructure ) -
FCKeditor/trunk/_whatsnew.html
r866 r908 257 257 <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1227">#1227</a>] The color 258 258 commands used an unnecessary temporary variable. Thanks to Matthias Miller</li> 259 <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/389">#389</a>] Pasting text with 260 comments from Word won't generate errors in IE, thanks to the idea from Swift.</li> 261 <li>The pasting area in the Paste from Word dialog is focused on initial load</li> 262 <li>Some fixes related to html comment handling in the Word clean up routine</li> 259 263 </ul> 260 264 <h3>