zoukankan      html  css  js  c++  java
  • extjs4 与 kindeditor

    <link rel="stylesheet" href="<?php echo Yii::app()->request->baseUrl;?>/kindeditor/themes/default/default.css" />
    <link rel="stylesheet" href="<?php echo Yii::app()->request->baseUrl;?>/kindeditor/plugins/code/prettify.css" />
    <script charset="utf-8" src="<?php echo Yii::app()->request->baseUrl;?>/kindeditor/kindeditor.js"></script>
    <script charset="utf-8" src="<?php echo Yii::app()->request->baseUrl;?>/kindeditor/lang/zh_CN.js"></script>
    <script charset="utf-8" src="<?php echo Yii::app()->request->baseUrl;?>/kindeditor/plugins/code/prettify.js"></script>
    <script type="text/javascript">
    Ext.require(['*']);
    
    Ext.onReady(function(){
     Ext.QuickTips.init();
      /**
         * 信息内容
         */
        var content = new Ext.form.TextArea(
                {
                    fieldLabel : '信息内容',
                    maxLength : '1000',
                    height : 150,
                    maxLengthText : '文章提示信息长度不能超过2000字',
                    name : 'content',
                    id : 'content',
                    emptyText : '无',
                    anchor : '80%',
                    listeners : {
                        "render" : function(f) {
                            K = KindEditor;
                            htmlEditor = K
                                    .create('#content',
                                            {
                                                uploadJson : '<?php echo Yii::app()->request->baseUrl;?>/kindeditor/php/upload_json.php',//路径自己改一下
                                                fileManagerJson : '<?php echo Yii::app()->request->baseUrl;?>/kindeditor/php/file_manager_json.php',//路径自己改一下
                                                height : 200,
                                                width : '90%',
                                                // fontSizeTable:['21px','20px','17px','18px','16px','14px','12px'],
                                                resizeType : 1,
                                                allowPreviewEmoticons : true,
                                                allowImageUpload : true
                                            });
                        }
                    }
                });
    
        var myForm = Ext.create('Ext.form.Panel',{
      layout:'absolute',
      url:'',
      defaultType:'textfield',
      border:true,
      items:[content]
     });
     var win = Ext.create('Ext.window.Window', {
            autoShow: true,
            title: 'Resize Me',
             800,
            height: 300,
            minWidth: 300,
            minHeight: 200,
            layout: 'fit',
            iconCls: 'icon_add',
            plain:true,
            items: myForm,
    
            buttons: [{
                text: 'Send'
            },{
                text: 'Cancel'
            }]
        });
     
    });
    </script>
    
  • 相关阅读:
    cocostudio 使用教程
    anrdroid AVD启动不起来的问题。Waiting for HOME ('android.process.acore') to be launched
    Android SDK无法更新的问题解决办法
    Code(容斥,好题)
    莫比乌斯反演(转)
    随笔--新建查询
    11427
    uva11722
    uva11021
    How many integers can you find(容斥+dfs容斥)
  • 原文地址:https://www.cnblogs.com/haiwei_sun/p/3501904.html
Copyright © 2011-2022 走看看