如何获取和编辑其中具有预设值的 tinymce 编辑器值

how to fetch & edit tinymce editor values which has a pre-set value in it

伙计们我正在尝试在 tinymce 编辑器中获取用户键入的值,该编辑器中已经有一个动态设置的值。问题是我无法在编辑器中获取编辑后的值,因为它 returns 在使用警报弹出窗口进行测试时仅动态预设值。那么我应该怎么做才能在编辑器中获取编辑后的值。

编辑器中动态设置值的代码如下:

$statusui_edit="<div type='".$updateid."' class='hidden_edit_4_session session_editor".$updateid." jumbotron'>"
            . "<a href='#' type='".$updateid."' class='pull-right close_edit' title='Close without editing'>Close X</a>"
            . "<input type='text' class='form-control title_s_edit title_s_".$updateid."' name='status_title' value='".html_entity_decode($title)."' placeholder='Title' >"
            . "<div>&nbsp;</div>"
            . "<textarea id='wall_edit_1' type='".$updateid."' rows='5' cols='50'  class='session_edit text_value_".$updateid."' wrap='hard' placeholder='whats up ".$session_uname."'>
             ".html_entity_decode($data)."</textarea><br>"
            . "<button style='float:right;' attrid='".$updateid."' type='a' class='btn btn-warning btn btn-large btn-lg post-s-edit'>Update</button></div>";

这是我用来编辑 tinymce 编辑器值的 jquery 代码:

$(".post-s-edit").click(function(){
  var attrid=$(this).attr('attrid');
  var title= $(".text_s_"+attrid).val();
 var data=$(".text_value_"+attrid).val();
 alert(title);
 alert(data);

        /*$.post(
          "status/update_status_ajax.php",


        );*/
});

你可以试试这个:-

tinyMCE.activeEditor.getContent();

详细信息:Click here