zoukankan      html  css  js  c++  java
  • 一个页面如何放多个百度编辑器 Ueditor 1.4.3?PHP如何获取Ueditor 的值?

    问题1:一个页面如何放置多个Ueditor?

    参考代码如下:

    <form  method="post" action="save.php">

    <script type="text/plain" id="ueditorId_1" name="ueditorName_1" style=" 400px;height:500px;">编辑器的默认值_1</script>

    <script type="text/javascript">
        UE.getEditor('ueditorId_1');
    </script>

    <script type="text/plain" id="ueditorId_2" name="ueditorName_2" style=" 450px;height:550px;">编辑器的默认值_2</script>

    <script type="text/javascript">
        UE.getEditor('ueditorId_2');
    </script>

    </form>

    这样,就会在页面中渲染2个Ueditor编辑器。

    问题2:PHP如何获取Ueditor的值?

    注意,上面的 ueditorName_1ueditorName_2 即为表单的Name值,所以服务端PHP获取Ueditor编辑器的值变得很简单,参考代码如下:

    $_POST["ueditorName_1"];  // 第一个编辑器的值

    $_POST["ueditorName_2"];  // 第二个编辑器的值

  • 相关阅读:
    Kostya the Sculptor
    Parade
    zoj 1097 普吕弗序列
    API分析——Jquery UI Dialog
    伸缩性和可用性反模式(转)
    可伸缩性最佳实战(转)
    二叉索引树BIT
    RMQ
    线段树(区间树)
    双栈计算算术表达式
  • 原文地址:https://www.cnblogs.com/52php/p/5680943.html
Copyright © 2011-2022 走看看