日期:2014-05-16  浏览次数:20388 次

JSP获取系统时刻

获得系统此刻时间的代码
?Timestamp stamp = new Timestamp(new Date().getTime());
?SimpleDateFormat format=new SimpleDateFormat("yyyy-MM-dd hh:mm:ss");
?String thistime = format.format(stamp);

??System.out.println(thistime);