zoukankan      html  css  js  c++  java
  • easyUI学习笔记一

    1.引用js文件

        <script type="text/javascript" src = jquery-easyui/jquery.min.js> </script>
        <script type="text/javascript" src = jquery-easyui/jquery.easyui.min.js> </script>
        <script type="text/javascript" src = jquery-easyui/locale/easyui-lang-zh_CN.js> </script>
        <script type="text/javascript" src ="index.js"></script>  <!-- 自定义js -->
    View Code

    2.引用css文件

    <link rel="stylesheet"  href="jquery-easyui/themes/default/easyui.css">
        <link rel="stylesheet"  href="jquery-easyui/themes/icon.css">
    View Code

    3.第一个demo

    <!DOCTYPE html>
    <html>
    <head>
        <title>easyui学习</title>
        <script type="text/javascript" src = jquery-easyui/jquery.min.js> </script>
        <script type="text/javascript" src = jquery-easyui/jquery.easyui.min.js> </script>
        <script type="text/javascript" src = jquery-easyui/locale/easyui-lang-zh_CN.js> </script>
        <link rel="stylesheet"  href="jquery-easyui/themes/default/easyui.css">
        <link rel="stylesheet"  href="jquery-easyui/themes/icon.css">
    </head>
    <body>
    <div class="easyui-dialog" style="500px;height:500px" data-options="title:'标题 ',collapsible:true,iconCls:'icon-ok'">
    内容部分</div>
    
    </body>
    </html>
    View Code

    4.js调用dialog

       <div id ="box" title="标题" style="500px;height:500px">
            内容部分
      </div>
    View Code
    $(function(){
        $('#box').dialog();
    })
    View Code

    5.可拖动

    $(function(){
    
             $('#box').draggable();
    
    })
    View Code

    6.拖放Droppable

    <!DOCTYPE html>
    <html>
    <head>
        <title>easyui学习</title>
        <script type="text/javascript" src = jquery-easyui/jquery.min.js> </script>
        <script type="text/javascript" src = jquery-easyui/jquery.easyui.min.js> </script>
        <script type="text/javascript" src = jquery-easyui/locale/easyui-lang-zh_CN.js> </script>
    
        <script type="text/javascript" src ="index.js"></script>  <!-- 自定义js -->
    
        <link rel="stylesheet"  href="jquery-easyui/themes/default/easyui.css">
        <link rel="stylesheet"  href="jquery-easyui/themes/icon.css">
    </head>
    <body>
    <div id="dd"  style=" 600px;height: 600px;background-color:red;" ></div>
    
      <div id ="box" title="标题" style="500px;height:500px;background-color: green;">
            <span id="span">内容部分</span>
      </div>
    
    <!--    <div id ="box" title="标题" style="500px;height:500px">
            内容部分
      </div> -->
    </div>
            
    </body>
    </html>
    View Code
    $(function(){
    $("#dd").droppable({
    accept:'#box',
    onDragEnter:function(e,source){
      $(this).css("background-color",'blue');
    },
    onDragLeave:function(e,source){
      $(this).css("background-color",'red');
    }
    });
    
        $('#box').draggable();
    })
    View Code
  • 相关阅读:
    js点击改变元素标签的样式JQ,动态加减class样式
    设置OFFICE默认比例,不分成两栏
    如何更改win7任务管理器的背景。ctrl+alt+delete调出来的界面的背景
    SQLServer 查询分析器里大小写转换快捷键
    SQL Server查询分析器里语句执行事务控制,防止增删改错
    JS生成二维码,文字,URL生成动态二维码,并在GridView里动态调用
    GridView动态绑定字段做参数,动态调用JS传参-JS
    sql server分页语句原始语句
    SQL 查询--日期条件(今日、昨日、本周、本月)
    将UIWebView显示的内容转为图片和PDF
  • 原文地址:https://www.cnblogs.com/SoftWareIe/p/10990808.html
Copyright © 2011-2022 走看看