
Java
沉小房
一个不入流的程序猿~
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
有关request.getScheme()
String path = request.getContextPath(); String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"; <base href="<%=basePath%>"> request.getSchema() 可以返回当前页原创 2016-10-21 16:16:21 · 426 阅读 · 0 评论 -
计算N天之后的日期函数
1、获取当前日期N天之后的日期(N为正数则后推,N为负数则向前推)public static String afterNDay(int n){ Calendar c=Calendar.getInstance(); DateFormat df=new SimpleDateFormat("yyyy-MM-dd"); c.setTime(new Date()); c.a原创 2016-12-04 17:25:45 · 2074 阅读 · 0 评论