issue 1185, trim iframe body after init, add new line after </p>

git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@10396 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
flyskyko 2012-03-08 07:40:45 +00:00
parent 65a124302b
commit a0c4134699
4 changed files with 40 additions and 29 deletions

View file

@ -11,7 +11,7 @@ function editorStart_xe(editor_sequence, primary_key, content_key, editor_height
var target_src = request_uri+'modules/editor/styles/'+content_style+'/editor.html';
var textarea = jQuery("#xpress-editor-"+editor_sequence);
var iframe = jQuery('<iframe id="editor_iframe_'+editor_sequence+'" allowTransparency="true" frameborder="0" src="'+target_src+'" scrolling="yes" style="width:100%;height:'+editor_height+'px">');
var iframe = jQuery('<iframe id="editor_iframe_'+editor_sequence+'" allowTransparency="true" frameborder="0" src="'+target_src+'" scrolling="yes" style="width:100%;height:'+editor_height+'px"></iframe>');
var htmlsrc = jQuery('<textarea rows="8" cols="42" class="input_syntax '+colorset+'" style="display:none"></textarea>');
var form = textarea.get(0).form;
form.setAttribute('editor_sequence', editor_sequence);
@ -121,6 +121,7 @@ function editorStart_xe(editor_sequence, primary_key, content_key, editor_height
if (doc.location == 'about:blank') throw 'blank';
// get innerHTML
doc.body.innerHTML = doc.body.innerHTML.trim();
str = doc.body.innerHTML;
// register plugin