zoukankan      html  css  js  c++  java
  • ckeditor使用

    参考:https://www.jb51.net/article/86500.htm
    https://www.cnblogs.com/Tirisfal/p/5548424.html
    #### 注意用标准版的没有背景色文字颜色等功能,所以配置了toolbar也不会显示此功能,需要下载full版本
    
    {% load staticfiles %}
    
    <!DOCTYPE html>
    <html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>Title</title>
    {#    <script type="text/javascript" src="/static/ckeditor/ckeditor.js"></script>#}
        <script type="text/javascript" src="{% static 'ckeditor/ckeditor.js' %}"></script>
        <script type="text/javascript" src="{% static 'ckeditor/config.js' %}"></script>
    {#    <script src="//cdn.ckeditor.com/4.4.6/full/ckeditor.js"></script>#}
    </head>
    
    <body>
    <form action="">
        <textarea id="TextArea1" cols="20" name="ss" rows="2" class="ckeditor"></textarea>
        
        <script type="text/javascript">
               
        CKEDITOR.replace('TextArea1',
        { toolbar:'Basic', height:300,1000 });
        //如果是在ASP.NET环境下用的服务器端控 件<TextBox>
        //CKEDITOR.replace('tbContent');
        //如 果<TextBox>控件在母版页中,要这样写
        //CKEDITOR.replace('<%=tbContent.ClientID.Replace("_","$") %>');
                  
    </script>
        <input type="submit">
    </form>
    </body>
    </html>
    
  • 相关阅读:
    微信小程序发送模板消息
    Swoole-WebSocket服务端主动推送消息
    git 批量删除分支
    RdKafka使用
    Kakfa安装,PHP安装RdKafka扩展
    Zookeeper安装、启动、启动失败原因
    Hyperf-事件机制+异常处理
    Hyperf-JsonRpc使用
    hyperf-环境搭建
    CGI、FastCGI、PHPFPM
  • 原文地址:https://www.cnblogs.com/lajiao/p/9266063.html
Copyright © 2011-2022 走看看