pretender
wenlong342 · 共 27 篇文章
hibernate分页
新建表 DROP DATABASE IF EXISTS `wjcms`; CREATE DATABASE `wjcms` /*!40100 DEFAULT CHARACTER SET gb2312 */; USE `wjcms`; # # Table structure for table t_article # CREATE TABLE `t_article` ( `a_id` int(11) NOT NULL auto_increment, `a_sort` int(11) NOT NULL default '0', `a_title` varchar(50) default NULL,…
2008-03-10 15:09 · hibernate · 评论(0)
个人整理的display的一些特性
display学习笔记 1.遇到写入request中的集合,翻页的时候显示不了?解决:把<display:table>加入requestURI="displayList.do"即可。 2.当无数据记录时,displaytag默认会输出 “Nothing found to display.”,而且没有表头。 修改displaytag.jar中的TableTag.properties文件的三处,就可以定制输出的消息和样式。 1) basic.empty.showtable=false 将属性设置为true,表头即可出现。 2)basic.msg.empty_list=Nothing found …
2008-03-07 14:38 · struts · 评论(0)
liferay中应用jspsmartupload+servlet实现上传
package com.sict.seller.servlet; import java.io.IOException; import java.text.DateFormat; import java.util.Date; import java.util.TimeZone; import javax.servlet.ServletConfig; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest;…
2008-03-06 15:37 · liferay · 评论(0)
hibernate管理session的例子
package com.sict.employeeManagement.help; import org.hibernate.HibernateException; import org.hibernate.Session; import org.hibernate.SessionFactory; import org.hibernate.cfg.Configuration; public class HibernateUtil { public static SessionFactory getSessionFactory() { return _instance._sessionFact…
2008-03-06 15:34 · hibernate · 评论(0)
struts+hibernate的分页代码
package com.sict.employeeManagement.help; import java.util.ArrayList; import java.util.Iterator; import com.sict.employeeManagement.data.SzEmployee; public class PageBean { int currentPage=1; //当前页 public int totalPages=0; //总页数 int pageRecorders=10;//每页5条数据 int totalRows=0; //总数据数 int pageStartRow…
2008-03-06 15:33 · struts · 评论(0)
网页中嵌入的天气预报的代码
<iframe src="http://www.tianqi123.com/php/current_city.php" mce_src="http://www.tianqi123.com/php/current_city.php" width=178 height=248 marginwidth=0 marginheight=0 hspace=0 vspace=0 frameborder=0 scrolling=no align=center id=url></iframe> 效果见地址:http://www.tianqi123.com/php/current_city.php <ifram…
2008-03-06 15:22 · other · 评论(0)
AspectJ初解
2006/10/30 AspectJ入門 AspectJ入门 入門-利用Eclipse編譯AspectJ入门-利用Eclipse编译AspectJ http://www.matrix.org.cn/resource/article/44/44423_Eclipse+AspectJ.html 如何使用AspectJ Compiler開發AspectJ程式如何使用AspectJ Compiler开发AspectJ程式 http://swanky.hsiao.googlepages.com/aspectj-with-ajc 以下出處: http://www-128.ibm.com/develope…
2008-02-22 14:46 · spring · 评论(0)
java excel api读写excel
Java Excel是一开放源码项目,通过它Java开发人员可以读取Excel文件的内容、创建新的Excel文件、更新已经存在的Excel文件。使用该API非Windows操作系统也可以通过纯Java应用来处理Excel数据表。因为是使用Java编写的,所以我们在Web应用中可以通过JSP、Servlet来调用API实现对Excel数据表的访问。 提供以下功能: 从Excel 95、97、2000等格式的文件中读取数据; 读取Excel公式(可以读取Excel 97以后的公式); 生成Excel数据表(格式为Excel 97); 支持字体、数字、日期的格式化; 支持单元格的阴影操作,以及颜色…
2008-02-20 13:11 · java · 评论(1)
hibernate官网上的管理session的例子
package sict.wenlong.operation; import org.hibernate.HibernateException; import org.hibernate.Session; import org.hibernate.SessionFactory; import org.hibernate.cfg.Configuration; public class HibernateUitl { private static SessionFactory sessionFactory; static{ try{ sessionFactory = new Configurat…
2008-01-23 18:49 · hibernate · 评论(0)
jspsmartupload下载
download.html <!-- 文件名:download.html 作 者:纵横软件制作中心雨亦奇( zhsoft88@sohu.com ) --> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>下载</title> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> </head> <body> <a href="do_download.jsp">点击下载</a> </body…
2008-01-18 13:10 · jsp · 评论(1)
jspsmartupload上传
upload.html <!doctype html public "-//w3c//dtd html 4.01 transitional//en"> <html> <head> <title>文件上传</title> <meta http-equiv="content-type" content="text/html; charset=gb2312"> <style type="text/css"> <!-- .style1 {font-size: 12px} .style2 {color: #006699} .style4 {font-size: 12px; color: #0066CC…
2008-01-18 13:08 · jsp · 评论(0)
获取当前系统北京时区的时间
import java.util.Date Date time=new Date(); DateFormat gmt08Formatter=DateFormat.getDateTimeInstance(); TimeZone timezone=TimeZone.getTimeZone("GMT+08:00"); gmt08Formatter.setTimeZone(timezone); // 获得格式化后的东八区时间 String gmt08DateTime=gmt08Formatter.format(time); System.out.println(gmt08DateTime);
2008-01-11 14:43 · java · 评论(0)
ajax的基础实现
<%@ page contentType="text/html;charset=gb2312"%> <html> <head> <title>实时列表数据</title> <style type="text/css"> <!-- .STYLE1 { font-size: 18px; font-weight: bold; color: #0000FF; } .style2 { font-size: 16px; } .style3 { font-size: 12px; } .style4{ font-size: 12px; color:#f00; } .style5{ font-size: 12…
2008-01-11 11:12 · ajax · 评论(0)
jsp注册验证码的实现
包括以下三个文件 a.jsp <%@ page contentType="text/html;charset=gb2312" %> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>认证码输入页面</title> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <META HTTP-EQUIV="Pragma" CONTENT="no-cache"> <META HTTP-EQUIV=…
2008-01-11 11:07 · jsp · 评论(0)