Ticket #29526: 29526.patch
| File 29526.patch, 763 bytes (added by , 11 years ago) |
|---|
-
src/wp-includes/js/mce-view.js
877 877 878 878 wp.mce.views.register( 'embedURL', _.extend( {}, wp.mce.embedMixin, { 879 879 toView: function( content ) { 880 var re = /( ?:^|<p>)(https?:\/\/[^\s"]+?)(?:<\/p>\s*|$)/gi,880 var re = /(^|<p>)(https?:\/\/[^\s"]+?)(<\/p>\s*|$)/gi, 881 881 match = re.exec( tinymce.trim( content ) ); 882 882 883 883 if ( ! match ) { … … 885 885 } 886 886 887 887 return { 888 index: match.index ,889 content: match[ 0],888 index: match.index + match[1].length, 889 content: match[2], 890 890 options: { 891 url: match[ 1]891 url: match[2] 892 892 } 893 893 }; 894 894 }