zoukankan      html  css  js  c++  java
  • 加载Editor

       <div id="contentDiv" style = " 98% ;height:100%; clear: both;margin-top: 10px;display:none;">
        <script id="content" name="content" type="text/plain" ></script>
       </div>

    $(function(){

       introduceEditor = UE.getEditor('content');
        var selectPath = '<%=request.getContextPath()%>/advertisement/selectAdvertHelp';
            $.post(selectPath,null,function(result)
              {
             if(result.success){
               $('#fm').form('load',result.advert);
                   $("#contentDiv").css("display","block");
              //Editor加载数据
               introduceEditor.ready(function(){
                   introduceEditor.setContent(result.advert.content);   
                  })
              
               
             }else{
              $.messager.alert('警告','查询错误!');
             }
             
            },'json');

    }

    查看去掉编辑框

    <body id='body'>

    </body>

     $(function() {    

       var selectPath = '<%=request.getContextPath()%>/advertisement/selectAdvertHelp';    

      $.ajax({    

       type : "GET",   

       url : selectPath,     

      data : null,     

      dataType : "json",     

      success : function(data) {    

        if (data.success == true) {       
        $("#body").append(data.help.content);

         } else {       

        $.messager.alert("操作提示", "操作失败!", "error");     

     }

        },     error : function() {      $.messager.alert("操作提示", "操作失败!", "error");     }    });    });

  • 相关阅读:
    ioctl函数用法小记
    scanf函数用法小记
    printf函数用法小记
    REDIS
    lspci 虚拟机网卡对应关系
    vmware安装ubuntu " Intel VT-x 处于禁用状态"
    win10远程桌面配置
    Win10如何彻底禁用小娜?彻底禁用小娜的方法
    为什么Windows7打开项目的方式是灰的不能修改
    以下suse11.3x64可以安装pycrypto-2.6.1
  • 原文地址:https://www.cnblogs.com/cuijinlong/p/6554372.html
Copyright © 2011-2022 走看看