`
woai671
  • 浏览: 29900 次
社区版块
存档分类
最新评论
文章列表
C#中方法的参数里经常会出现object sender与EventArgs e 前者是一个对象(其实这里传递的是对象的引用,如果是button1的click事件则sender就是button1); 后面是包含事件数据的类的基类。

sql 按时间查询

    博客分类:
  • SQL
----今日------ SELECT * FROM 表名 WHERE datediff(day,字段名,getdate())=0; ----昨天------ SELECT * FROM 表名 WHERE datediff(day,字段名,getdate())=1; -----本月----- select * from 表名 where datepart(mm,字段名)=datepart(mm,getdate()) -----今年------ select * from 表名 where da ...

SQL 部分查询

    博客分类:
  • SQL
select Row,title from (SELECT ROW_NUMBER() OVER (ORDER BY id) AS ROW,title from 表名) AS 表1 where ROW>=起始 and ROW<=结束;
select * from 表名 where dateadd(day,datediff(day,0,时间记录字段),0)='指定日期'
HTML不允许Form嵌套,但是我们可以通过控制Form的action,实现多个form的效果: <script language=javascript> function process(v){ if(v=="in"){ document.theForm.action="in.jsp"; }else{ document.theForm.action="out.jsp"; } document.theForm. ...
在程序中,从数据库中读取到的日期时间类型数据一般是这种格式:"/Date(139832079+0800)/" 我们要让它转换为这种形式:'2012-12-10 11:05:21' 可用如下js函数: function timeFormatter(value) { var t = new Date(parseInt(value.replace("/Date(", "").replace(")/" , "").split( "+")[0])); r ...
function GetDate(value) { var username; $.ajax({ type: "post", url: "ashx/MD5.ashx", data: "PW=" + value, success: function (result) { Encipher = result; } }); return Enciph ...
很多时候点击ImageButton目的只是为了更改页面部分内容,不需要刷新页面,解决方案如下: $("#search").click(function () { return false;});
document.documentElement.scrollTop = document.body.scrollTop =0;

div自动居中

让div自动居中: //定义宽度,不定义宽度无效 witdh:200px; //关键 margin:0 auto;
Global site tag (gtag.js) - Google Analytics