上一页 1 2 3 4 5 6 7 8 9 ··· 29 下一页

js新闻滚动播放

摘要: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html><head><title> code.js.cn </title><style>a{display:block;font-size:15px;line-height:18px;text-decoration:none;color:#333;font-famil 阅读全文
posted @ 2013-06-06 14:35 专注2018 阅读(2159) 评论(2) 推荐(0) 编辑

ajax无参数刷新页面

摘要: <c:set var="ctx" value="${pageContext.request.contextPath}"/> <input type="hidden" name="appPath_" value="${ctx}" id="appPath_"/> function refreshLbye() { var appPath_ = $("#appPath_").val(); $.ajax({ type: "POST& 阅读全文
posted @ 2013-06-03 18:19 专注2018 阅读(213) 评论(0) 推荐(0) 编辑

MySQL日期时间函数大全

摘要: http://www.cnblogs.com/zeroone/archive/2010/05/05/1727659.html 阅读全文
posted @ 2013-05-30 14:01 专注2018 阅读(121) 评论(0) 推荐(0) 编辑

通过js实现时间,日期等的显示

摘要: 问题:如图中,用js实现年月日,星期的显示。具体代码:<script type="text/javascript">$(function() { var myDate = new Date(); xinqu_nian.innerHTML = myDate.toLocaleDateString().substring(0,7);//年月 xinqu_ri.innerHTML = myDate.getDate();//日 xinqu_rihgt.innerHTML = myDate.toLocaleDateString()+' 星期'+'日一 阅读全文
posted @ 2013-05-24 11:02 专注2018 阅读(457) 评论(0) 推荐(0) 编辑

Target runtime Apache Tomcat v5.0 is not defined. 的解决方法

摘要: 解决方法:在工程目录下的.settings文件夹里,打开org.eclipse.wst.common.project.facet.core.xml文件。显示<?xml version="1.0" encoding="UTF-8"?>< faceted-project><runtime name="Apache Tomcat v5.0"/>< fixed facet="jst.web"/>< fixed facet="jst.java"/> 阅读全文
posted @ 2013-05-16 18:23 专注2018 阅读(229) 评论(0) 推荐(0) 编辑

MySql 里的IFNULL、NULLIF和ISNULL用法

摘要: isnull(expr) 的用法: 如expr 为null,那么isnull() 的返回值为 1,否则返回值为 0。 mysql> select isnull(1+1); -> 0 mysql> select isnull(1/0); -> 1 使用= 的null 值对比通常是错误的。isnull() 函数同 is null比较操作符具有一些相同的特性。请参见有关is null 的说明。IFNULL(expr1,expr2)的用法:假如expr1 不为NULL,则 IFNULL() 的返回值为 expr1; 否则其返回值为 expr2。IFNULL()的返回值是数字或是 阅读全文
posted @ 2013-05-15 17:45 专注2018 阅读(239) 评论(0) 推荐(0) 编辑

对日期格式的处理,小技巧01

摘要: 1、java代码中:String createtime = map.get("createtime").toString().substring(0, 19);// 结果为2013-05-15 09:05:13String createtime = map.get("createtime").toString().substring(0, 11);// 结果为2013-05-152、MySqlSELECT DATE_FORMAT(时间,'%Y-%m-%d') FROM 表名 阅读全文
posted @ 2013-05-15 16:35 专注2018 阅读(159) 评论(0) 推荐(0) 编辑

JQuery中$.ajax()方法参数详解

摘要: url: 要求为String类型的参数,(默认为当前页地址)发送请求的地址。type: 要求为String类型的参数,请求方式(post或get)默认为get。注意其他http请求方法,例如put和 delete也可以使用,但仅部分浏览器支持。timeout: 要求为Number类型的参数,设置请求超时时间(毫秒)。此设置将覆盖$.ajaxSetup()方法的全局设 置。async:要求为Boolean类型的参数,默认设置为true,所有请求均为异步请求。 如果需要发送同步请求,请将此选项设置为false。注意,同步请求将锁住浏览器,用户其他操作必须等 待请求完成才可以执行。cache:要求为 阅读全文
posted @ 2013-05-10 13:54 专注2018 阅读(187) 评论(0) 推荐(0) 编辑

网站刷新时,随机有些操作业务问题

摘要: $(function(){ kobe();}function kobe(){ var cs = 2; var now = new Date(); var sec = now.getSeconds(); var ad = sec % cs; alert(ad);//结果是1或0 if() { 业务的处理 } else { 业务的处理 }} 阅读全文
posted @ 2013-05-10 11:41 专注2018 阅读(178) 评论(0) 推荐(0) 编辑

bufferedreader操作文件出现Connection timed out异常

摘要: int count=0; String urlStr ="http://地址";try{ URL url = new URL(urlStr); BufferedReader reader = new BufferedReader(new InputStreamReader(url.openStream(),"GBK")); String line=null; do { line = reader.readLine(); if(line!=null) { str +=line;} } while(line!=null); reader.close(); c 阅读全文
posted @ 2013-05-09 17:08 专注2018 阅读(229) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 29 下一页