http://www.javacamp.org/designPattern/
http://www.fluffycat.com/Java-Design-Patterns/Composite/
http://www.javaworld.com/channel_content/jw-patterns-index.html
posted @
2007-04-03 08:37 選寶網(wǎng)an9 閱讀(297) |
評論 (0) |
編輯 收藏
默認安裝tomcat5然后在catalina.bat最前面加入set JAVA_OPTS=-Xms128m -Xmx350m 如果用startup.bat啟動tomcat,OK設置生效.夠成功的分配200M內(nèi)存.
但是如果不是執(zhí)行startup.bat啟動tomcat而是利用windows的系統(tǒng)服務啟動tomcat服務,上面的設置就不生效了,就是說set JAVA_OPTS=-Xms128m -Xmx350m 沒起作用.上面分配200M內(nèi)存就OOM了..
windows服務執(zhí)行的是bin\tomcat.exe.他讀取注冊表中的值,而不是catalina.bat的設置.
解決辦法:
修改注冊表HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Tomcat Service Manager\Tomcat5\Parameters\JavaOptions
原值為
-Dcatalina.home="C:\ApacheGroup\Tomcat 5.0"
-Djava.endorsed.dirs="C:\ApacheGroup\Tomcat 5.0\common\endorsed"
-Xrs
加入 -Xms300m -Xmx350m?
重起tomcat服務,設置生效
posted @
2007-03-27 10:49 選寶網(wǎng)an9 閱讀(1041) |
評論 (0) |
編輯 收藏
http://java.sun.com/docs/books/tutorial/javabeans/introspection/index.html
posted @
2007-03-21 08:04 選寶網(wǎng)an9 閱讀(145) |
評論 (0) |
編輯 收藏
1.mysql在本地localhost的test數(shù)據(jù)庫 建person表,暫以字段id,name,password?,表中可輸入一行值.
2.建類 DAOUtil
import ?java.sql.Connection;
import ?java.sql.DriverManager;
public class DAOUtil {
??? public DAOUtil() {
??? }
?? public static Connection getConn() {
??????? Connection conn = null;
??????? String db_url = "jdbc:mysql://127.0.0.1:3306/test?useUnicode=true&characterEncoding=gb2312";
??????? String db_user = "root";
??????? String db_password= "admin";
??????? String db_driver = "com.mysql.jdbc.Driver";
??????? try {
??????????? Class.forName(db_driver);
??????????? conn = DriverManager.getConnection(db_url, db_user, db_password);
???????????? } catch (Exception ex) {
???????????? ex.printStackTrace();
??????? }
??????? return conn;
??? }
? /**
? * dbclose
? * 關閉Connection,Statement
? * @param conn Connection
? * @param stmt Statement
? */
?public static void dbclose(Connection conn, Statement stmt) {
?????? try {
?????????? if (stmt != null)
?????????????? stmt.close();
?????? } catch (Exception e) {
???????? e.printStackTrace();
?????? }
?????? try {
?????????? if (conn != null)
?????????????? conn.close();
?????? } catch (Exception e) {
????????? e.printStackTrace();
?????? }
?? }
}
3.建類 PersonDAO
import java.util.*;
import java.sql.Connection;
import java.sql.Statement;
import java.sql.ResultSet;
public class PersonDAO {
??? static PersonDAO pdao;
??? public static PersonDAO getInstance() {
??????? if (pdao == null) {
??????????? synchronized (PersonDAO.class) {
??????????????? pdao = new PersonDAO();
??????????? }
??????? }
??????? return pdao;
??? }
??? public PersonDAO() {
??????? super();??? }
??? public static void main(String[] args) {
????????? System.out.println("person==="+PersonDAO.getInstance().getPersonInfo());
??? }
??
?????? private static List getPersonInfo() {
????????? String name? = "";
????????? String password = "";
????????? Connection conn = null;
????????? List list = new java.util.ArrayList();
????????? Statement stmt = null;
????????? String sql =
????????????????? "select name,password from person";
????????? try {
????????????? conn = DAOUtil.getConn();
????????????? stmt = conn.createStatement();
????????????? ResultSet rs = stmt.executeQuery(sql);
????????????? while (rs.next()) {
????????????????? name = (String)rs.getString("name");
????????????????? password = (String)rs.getString("password");
????????????????? list.add(name+","+password);
???????????????? }
????????? } catch (Exception ex) {
????????????? ex.printStackTrace();
?????????????? } finally {
????????????? DAOUtil.dbclose(conn, stmt);
????????? }
????????? return list;
????? }?
}
4.建testCache.jsp,testCache2.jsp
<%@page contentType="text/html; charset=GBK"%>
<%@page import="com.mcsky.dao.PersonDAO" session="false"%>
<%@page import="java.util.List" session="false"%>
<html>
<body bgcolor="#FFFFFF">
test ,hello world!!<p>
? <table width="85%" border="1" align="center">
?? <tr>
????? <td width="8%" height="20"> <div align="center">序號</div></td>
????? <td width="12%"><div align="center">名字</div></td>
????? <td width="17%"><div align="center">密碼 </div></td>
?????? </tr>
<%
//todo connect mysql server (localhost root/admin) and test(db) person(table)
List list =PersonDAO.getInstance().getPersonInfo();
System.out.println("size==="+list.size());
for(int i=0;i<list.size();i++){
String namePass = (String)list.get(i);
java.util.StringTokenizer st = new? java.util.StringTokenizer(namePass,",");
String?? name = st.nextToken();
String??? pass = st.nextToken();
System.out.println("namePass+++++"+namePass);
%>
? <tr>
????? <td><div align="center"><%=i+1%></div></td>
????? <td> <div align="center"><%=name%></div></td>
????? <td><div align="center"><%=pass%></div></td>
????? </tr>
??? <%
??????? }
%>
? </table>
</body>
</html>
5.把module部署在tomcat的webapp下
5.1 在WEB-INF\lib\log4j-1.2.8.jar,mysql-connector-java-3.0.11-stable-bin.jar,oscache-2.3.2.jar,commons-logging.jar,jgroups-all.jar
5.2 在WEB-INF\classes拷貝cach\etc\下的oscache.tld,oscache.properties
5.3 只對/testCache.jsp緩存
修改WEB-INF\web.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
? <display-name>test</display-name>
? <taglib><taglib-uri>oscache</taglib-uri><taglib-location>/WEB-INF/classes/ oscache.tld</taglib-location></taglib>
?? <filter>???
?? <filter-name>CacheFilter</filter-name>
?? <filter-class>com.opensymphony.oscache.web.filter.CacheFilter</filter-class>
?? </filter>
?? <filter-mapping>
?? <filter-name>CacheFilter</filter-name>?
?????? <url-pattern>/testCache.jsp</url-pattern>
????? </filter-mapping>????
</web-app>
啟動tomcat,在mysql的person中增加一條記錄,發(fā)現(xiàn)已對/testCache.jsp頁面進行緩存,而/testCache2.jsp頁面未緩存,如去掉黑體,則數(shù)據(jù)表增加一行,testCache.jsp也隨之修改
5.4對所有的jsp緩存,
修改WEB-INF\web.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
? <display-name>test</display-name>
????? <filter>???
??????? <filter-name>CacheFilter</filter-name>
??????? <filter-class>com.opensymphony.oscache.web.filter.CacheFilter</filter-class>
????????? <init-param>???????
?????????? <param-name>time</param-name>
??????????????????? <param-value>60</param-value>??
?????????? </init-param>???
????????? <init-param>???????????????????????????
????????? <param-name>scope</param-name>
???????????????????? <param-value>session</param-value>
????????? </init-param>
????????? </filter>
????????? <filter-mapping>
????????? <filter-name>CacheFilter
????????? </filter-name>
??????????? <url-pattern>*.jsp</url-pattern>
????????? </filter-mapping>
</web-app>
其中60s,是失效時間,在mysql的person中增加一條記錄,發(fā)現(xiàn)已對/testCache.jsp,/testCache2.jsp頁面進行緩存,頁面不變化,60s后頁面變化.
posted @
2007-03-17 09:15 選寶網(wǎng)an9 閱讀(221) |
評論 (0) |
編輯 收藏
我想把一個基于數(shù)據(jù)庫的WEB應用程序加上緩存,以提高性能,開源的java緩存系統(tǒng)不少,先拿JCS( Java Caching System)試試。
關于JCS的介紹,小紅帽的文章已寫得非常清楚了,附后。
先到http://jakarta.apache.org/jcs/Downloads.html
下載jcs-1.2.6.jar,找了半天也沒有找到它的源碼和API文檔,不知為什么?
在這個站點有: Using JCS: Some basics for the web ,不錯,就用它練習。
一、創(chuàng)建值對象
假設有一BOOK,它在數(shù)據(jù)庫中的表為:
Table BOOK
??BOOK_ID_PK
??TITLE
??AUTHOR
??ISBN
??PRICE
??PUBLISH_DATE
創(chuàng)建值對象如下:
package com.genericbookstore.data;
import java.io.Serializable;
import java.util.Date;
public class BookVObj implements Serializable
{
public int bookId = 0;
public String title;
public String author;
public String ISBN;
public String price;
public Date publishDate;
public BookVObj()
{
}
}
二、創(chuàng)建緩存管理器
應用中對book數(shù)據(jù)的訪問都通過緩存管理器。
package com.genericbookstore.data;
import org.apache.jcs.JCS;
// in case we want to set some special behavior
import org.apache.jcs.engine.behavior.IElementAttributes;
public class BookVObjManager
{
private static BookVObjManager instance;
private static int checkedOut = 0;
public static JCS bookCache;
private BookVObjManager()//構(gòu)造函數(shù)
{
try
{
bookCache = JCS.getInstance("bookCache");
}
catch (Exception e)
{
// Handle cache region initialization failure
}
// Do other initialization that may be necessary, such as getting
// references to any data access classes we may need to populate
// value objects later
}
/**
* Singleton access point to the manager.
*/
public static BookVObjManager getInstance()
{
synchronized (BookVObjManager.class)
{
if (instance == null)
{
instance = new BookVObjManager();
}
}
synchronized (instance)
{
instance.checkedOut++;
}
return instance;
}
/**
* Retrieves a BookVObj. Default to look in the cache.
*/
public BookVObj getBookVObj(int id)
{
return getBookVObj(id, true);
}
/**
* Retrieves a BookVObj. Second argument decides whether to look
* in the cache. Returns a new value object if one can't be
* loaded from the database. Database cache synchronization is
* handled by removing cache elements upon modification.
*/
public BookVObj getBookVObj(int id, boolean fromCache)
{
BookVObj vObj = null;
// First, if requested, attempt to load from cache
if (fromCache)
{
vObj = (BookVObj) bookCache.get("BookVObj" + id);
}
// Either fromCache was false or the object was not found, so
// call loadBookVObj to create it
if (vObj == null)
{
vObj = loadBookVObj(id);
}
return vObj;
}
/**
* Creates a BookVObj based on the id of the BOOK table. Data
* access could be direct JDBC, some or mapping tool, or an EJB.
*/
public BookVObj loadBookVObj(int id)
{
BookVObj vObj = new BookVObj();
vObj.bookId = id;
try
{
boolean found = false;
// load the data and set the rest of the fields
// set found to true if it was found
found = true;
// cache the value object if found
if (found)
{
// could use the defaults like this
// bookCache.put( "BookVObj" + id, vObj );
// or specify special characteristics
// put to cache
bookCache.put("BookVObj" + id, vObj);
}
}
catch (Exception e)
{
// Handle failure putting object to cache
}
return vObj;
}
/**
* Stores BookVObj's in database. Clears old items and caches
* new.
*/
public void storeBookVObj(BookVObj vObj)
{
try
{
// since any cached data is no longer valid, we should
// remove the item from the cache if it an update.
if (vObj.bookId != 0)
{
bookCache.remove("BookVObj" + vObj.bookId);
}
// put the new object in the cache
bookCache.put("BookVObj" + vObj.bookId, vObj);
}
catch (Exception e)
{
// Handle failure removing object or putting object to cache.
}
}
}
三、配置文件cache.ccf,它定義你配置何種類型的緩存、緩存的大小、過期時間等。
#WEB-INF/classes/cache.ccf(以下內(nèi)容不要換行)
jcs.default=
jcs.default.cacheattributes=org.apache.jcs.engine.CompositeCacheAttributes
jcs.default.cacheattributes.MaxObjects=1000
jcs.default.cacheattributes.MemoryCacheName=org.apache.jcs.engine.memory.lru.LRUMemoryCache
jcs.default.cacheattributes.UseMemoryShrinker=true
jcs.default.cacheattributes.MaxMemoryIdleTimeSeconds=3600
jcs.default.cacheattributes.ShrinkerIntervalSeconds=60
jcs.default.cacheattributes.MaxSpoolPerRun=500
jcs.default.elementattributes=org.apache.jcs.engine.ElementAttributes
jcs.default.elementattributes.IsEternal=false
四、測試的JSP文件
<%@page import="com.genericbookstore.data.*,java.util.*" %>
<%
BookVObjManager cache = BookVObjManager.getInstance();
BookVObj bv1=cache.getBookVObj(8,true);
out.println(bv1.bookId);
%>
五、測試:http://127.0.0.1:8080/jcs/testjcs.jsp
所有源文件請下載。
附:
JCS(Java Caching System)簡介以及相關文檔作者:小紅帽
概述
JCS是Jakarta的項目Turbine的子項目。它是一個復合式的緩沖工具??梢詫ο缶彌_到內(nèi)存、硬盤。具有緩沖對象時間過期設定。還可以通過JCS構(gòu)建具有緩沖的分布式構(gòu)架,以實現(xiàn)高性能的應用。
對于一些需要頻繁訪問而每訪問一次都非常消耗資源的對象,可以臨時存放在緩沖區(qū)中,這樣可以提高服務的性能。而JCS正是一個很好的緩沖工具。緩沖工具對于讀操作遠遠多于寫操作的應用性能提高非常顯著。
JCS的詳細說明在 http://jakarta.apache.org/turbine/jcs/
JCS的特性
JCS除了簡單的將對象緩沖在內(nèi)存中以外,還具有幾個特性,以適應企業(yè)級緩沖系統(tǒng)的需要。這些特性包括時間過期、索引式硬盤緩沖、并行式的分布緩沖等。
內(nèi)存緩沖
JCS現(xiàn)在支持兩種內(nèi)存緩沖算法LRU和MRU。通常都是使用LRU算法。
org.apache.stratum.jcs.engine.memory.lru.LRUMemoryCache
使用內(nèi)存緩沖區(qū)需要定義緩沖區(qū)大小,當超過緩沖區(qū)限制時,會將緩沖內(nèi)容拋棄掉。如果有配硬盤緩沖,則將擠出來的緩沖內(nèi)容寫入硬盤緩沖區(qū)。
時間過期
JCS對于緩沖的對象,可以設定緩沖過期時間,一個對象在緩沖區(qū)中停留的時間超過這個時間,就會被認為是“不新鮮”而被放棄。
索引式硬盤緩沖
一方面,為了避免緩沖區(qū)過大,撐爆虛擬機的內(nèi)存,另一方面又希望能夠緩沖更多的對象,JCS可以將超出緩沖區(qū)大小的對象緩存到硬盤上。配置上也比較方便, 只需要指定緩沖臨時文件的存放目錄位置。硬盤緩沖將緩沖對象的內(nèi)容寫到文件上,但是將訪問索引保存在內(nèi)存中,因此也能夠達到盡可能高的訪問效率。
并行式的分布緩沖(Lateral)
通常,將對象緩沖在內(nèi)存中,一方面提高了應用的性能,而另一方面卻使得應用不可以分布式發(fā)布。因為假設一個應用配置在兩臺服務器上并行運行,而兩臺服務器 單獨緩沖,則很容易導致兩個緩沖區(qū)內(nèi)容出現(xiàn)版本上的不一致而出錯。一個機器上修改了數(shù)據(jù),這個動作會影響到本地內(nèi)存緩沖區(qū)和數(shù)據(jù)庫服務器,但是卻不會通知 到另一臺服務器,導致另一臺上緩沖的數(shù)據(jù)實際上已經(jīng)無效了。
并行式的分布緩沖就是解決這個問題??梢酝ㄟ^配置,將幾臺服務器配成一個緩沖組,組內(nèi)每臺服務器上有數(shù)據(jù)更新,會橫向?qū)⒏碌膬?nèi)容通過TCP/IP協(xié)議傳 輸?shù)狡渌掌鞯木彌_層,這樣就可以保證不會出現(xiàn)上述情況。這個的缺點是如果組內(nèi)的并行的服務器數(shù)量增大后,組內(nèi)的數(shù)據(jù)傳輸量將會迅速上升。這種方案適合 并行服務器的數(shù)量比較少的情況。
Client/Server式的緩沖(Remote)
客戶/服務端式的緩沖集群。這種方式支持一個主服務器和最高達到256個客戶端。客戶端的緩沖層會嘗試連接主服務器,如果連接成功,就會在主服務器上注冊。每個客戶端有數(shù)據(jù)更新,就會通知到主服務器,主服務器會將更新通知到除消息來源的客戶端以外的所有的客戶端。
每個客戶端可以配置超過一個服務器,第一個服務器是主服務器,如果與第一個服務器連接失敗,客戶端會嘗試與備用的服務器連接,如果連接成功,就會通過備用 服務器與其他客戶端對話,同時會定期繼續(xù)嘗試與主服務器取得連接。如果備用服務器也連接失敗,就會按照配置順序嘗試與下一個備用服務器連接。
這種方式下,更新通知是一種輕量級的,一個機器上的數(shù)據(jù)更新,不會把整個數(shù)據(jù)傳輸出去,而只是通知一個ID,當遠程的其他機器收到更新通知后,就會把對應ID的緩沖對象從本地的內(nèi)存緩沖區(qū)中移除,以保證不會在緩沖區(qū)內(nèi)出現(xiàn)錯誤數(shù)據(jù)。
這種構(gòu)造需要分別配置客戶端和服務器,配置比較麻煩。
配置方法
JCS的好處之一,就是應用在開發(fā)的時候,可以不用去構(gòu)思底層的緩沖配置構(gòu)架。同一個應用,只需要修改配置,就可以改變緩沖構(gòu)架,不需要修改應用的源代 碼。配置方法也比較簡單,就是修改配置文件cache.ccf。這個文件放置在WEB-INF/classes目錄下。配置格式類似log4j的配置文件 格式。下面介紹一下使用各種緩沖結(jié)構(gòu)的配置方法。
內(nèi)存緩沖
#WEB-INF/classes/cache.ccf(以下內(nèi)容不要換行)
jcs.default=
jcs.default.cacheattributes=org.apache.jcs.engine.CompositeCacheAttributes
jcs.default.cacheattributes.MaxObjects=1000
jcs.default.cacheattributes.MemoryCacheName=org.apache.jcs.engine.memory.lru.LRUMemoryCache
上面配置了默認緩沖屬性。一個應用中,由于對象類型的不同,可能會使用多個緩沖區(qū),每個緩沖區(qū)都會有一個名字,如果在配置文件中沒有指明特定的緩沖區(qū)的屬 性,所有的緩沖區(qū)都會根據(jù)默認屬性來構(gòu)建。上面的內(nèi)容,指明緩沖區(qū)的大小為存放1000個對象,內(nèi)存緩沖器使用LRUMemoryCache對象??蛇x的 還有MRUMemoryCache,應該可以自定義新的內(nèi)存緩沖區(qū)。1000個緩沖對象這個容量,是指每個緩沖區(qū)都緩沖1000個,而不是指所有緩沖區(qū)總 容量。以上配置,就可以讓應用運行起來。
時間過期
如果需要引入時間過期機制,則需要加上
jcs.default.cacheattributes.cacheattributes.UseMemoryShrinker=true
jcs.default.cacheattributes.cacheattributes.MaxMemoryIdleTimeSeconds=3600
jcs.default.cacheattributes.cacheattributes.ShrinkerIntervalSeconds=60
這里指明對象超過3600秒則過期,每隔60秒檢查一次。
索引式硬盤緩沖
索引式硬盤緩沖是輔助緩沖的一種,使用時需要做以下事情
#定義一個硬盤緩沖區(qū)產(chǎn)生器(Factory),取名為DC
jcs.auxiliary.DC=org.apache.stratum.jcs.auxiliary.disk.indexed.IndexedDiskCacheFactory
jcs.auxiliary.DC.attributes=org.apache.stratum.jcs.auxiliary.disk.indexed.IndexedDiskCacheAttributes
jcs.auxiliary.DC.attributes.DiskPath=g:/dev/jakarta-turbine-stratum/raf
#這里其實就是指明了緩沖文件存放到那里去。
然后,做以下修改
jcs.default=DC
這樣,所有未特別指定屬性的緩沖區(qū)都會自己使用一個硬盤緩沖區(qū),緩沖文件會以緩沖區(qū)的名字來命名。存放在指定的目錄下。
橫向式的并行緩沖
并行式的配置如下
jcs.auxiliary.LTCP=org.apache.jcs.auxiliary.lateral.LateralCacheFactory
jcs.auxiliary.LTCP.attributes=org.apache.jcs.auxiliary.lateral.LateralCacheAttributes
jcs.auxiliary.LTCP.attributes.TransmissionTypeName=TCP
jcs.auxiliary.LTCP.attributes.TcpServers=192.168.10.129:1121,192.168.10.222:1121
jcs.auxiliary.LTCP.attributes.TcpListenerPort=1121
jcs.auxiliary.LTCP.attributes.PutOnlyMode=false
這里的配置是在41,129,221三臺機器上實現(xiàn)并行緩沖的。
大家都在1121端口上監(jiān)聽,同時與另外兩臺機器連接。如果連接失敗,就會等待一個時間后再連接一次,直到連接成功為止。三臺機器中任意一臺的緩沖區(qū)發(fā)生更新,比如put和remove動作,就會把更新傳遞給另外兩臺。
單獨指明某個緩沖區(qū)的屬性
如果,針對某個緩沖區(qū),比如叫做TestCache1,需要單獨配置屬性,可以如下配置。
jcs.region.testCache1=DC,LTCP
jcs.region.testCache1.cacheattributes=org.apache.stratum.jcs.engine.CompositeCacheAttributes
jcs.region.testCache1.cacheattributes.MaxObjects=1000
jcs.region.testCache1.cacheattributes.MemoryCacheName=org.apache.stratum.jcs.engine.memory.lru.LRUMemoryCache
jcs.region.testCache1.cacheattributes.UseMemoryShrinker=true
jcs.region.testCache1.cacheattributes.MaxMemoryIdleTimeSeconds=3600
jcs.region.testCache1.cacheattributes.ShrinkerIntervalSeconds=60
system.GroupIdCache
這個概念我也不是很清楚。不過JCS文檔中指出配置以下內(nèi)容會比較好。
jcs.system.groupIdCache=DC
jcs.system.groupIdCache.cacheattributes=org.apache.stratum.jcs.engine.CompositeCacheAttributes
jcs.system.groupIdCache.cacheattributes.MaxObjects=10000
jcs.system.groupIdCache.cacheattributes.MemoryCacheName=org.apache.stratum.jcs.engine.memory.lru.LRUMemoryCache
這可能是JCS自己的組管理體系上的緩沖區(qū)。
Client/Server式的緩沖(Remote)
這種構(gòu)架需要單獨配置客戶端和服務端,如果要研究,可以查看 http://jakarta.apache.org/turbine/jcs/RemoteAuxCache.html
posted @
2007-03-17 09:14 選寶網(wǎng)an9 閱讀(290) |
評論 (0) |
編輯 收藏
摘要:
閱讀全文
posted @
2007-03-02 11:06 選寶網(wǎng)an9 閱讀(423) |
評論 (0) |
編輯 收藏
從
數(shù)據(jù)庫中讀出圖片并顯示的示例代碼
< !-- -- -- --
Servlet-- -- -- -- -->
package Photo;
import
Javax.servlet.*;
import
javax.servlet.http.*;
import
java.io.*;
import
java.util.*;
import
java.lang.*;
import
java.sql.*;
/**
* <p>Title: </p>
* <p>Description: </p>
* <p>Copyright: Copyright (c) 2002</p>
* <p>Company: </p>
* @author unascribed
* @version 1.0
*/
public class ShowImage extends HttpServlet {
private static final String CONTENT_TYPE = "image/*";
/**
* 定義數(shù)據(jù)庫連接字符串,JDBC.odbc橋
*/
private String driver_class = "Oracle.jdbc.driver.OracleDriver";
private String connect_string =
"jdbc:oracle:thin:xxw/xxw@192.168.1.50:1521:ORCL";
Connection conn = null;
ResultSet rs = null;
Statement stmt = null;
/********************************************
* 定義應用變量
******************************************/
private String SQLString = ""; //定義查詢語句\\r
public String M_EorrMenage = ""; //定義錯誤信息變量
private InputStream in = null; //定義輸入流\\r
private int len = 10 * 1024 * 1024; //定義字符數(shù)組長度
//Initialize global variables
public void init() throws ServletException {
/**
* 連接數(shù)據(jù)庫\\r
*/
try {
Class.forName(driver_class);
} catch (java.lang.ClassNotFoundException e) {
//異常
System.err.println("databean():" + e.getMessage());
}
}
//Process the HTTP Get request
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
response.setContentType(CONTENT_TYPE);
PrintWriter out = response.getWriter();
//在數(shù)據(jù)庫中的照片的ID
int PHOTOID = 0;
/*********************************************
* 接受上文傳遞的圖片ID號
* 上文傳輸文件名稱為photoid
*********************************************/
try {
PHOTOID = Integer.parseInt(request.getParameter("photoid"));
SQLString = "select * from xxw_photo where p_id=" + PHOTOID;
} catch (Exception e) {
e.printStackTrace();
response.setContentType("text/html; charset=gb2312");
M_EorrMenage = "請輸入圖片ID號";
M_EorrMenage =
new String(M_EorrMenage.getBytes("ISO8859_1"), "GBK");
out.println("<%@ page contentType=\'text/html; charset=gb2312\' %>");
out.println("<html>");
out.println("<head><title>id</title></head>");
out.println("<body>");
out.println("<p>" + M_EorrMenage + "</p>");
out.println("</body></html>");
}
/*****************************************************
* 執(zhí)行查詢語句\\r
*****************************************************/
try {
conn = DriverManager.getConnection(connect_string);
stmt = conn.createStatement();
rs = stmt.executeQuery(SQLString);
} //try
catch (SQLException ex) {
System.err.println("aq.executeUpdate:" + ex.getMessage());
M_EorrMenage = "對不起,數(shù)據(jù)庫無法完成此操作!";
M_EorrMenage =
new String(M_EorrMenage.getBytes("ISO8859_1"), "GBK");
response.setContentType("text/html; charset=gb2312");
out.println("<html>");
out.println("<head><title>no_database</title></head>");
out.println("<body>");
out.println("<p>" + M_EorrMenage + "</p>");
out.println("</body></html>");
}
/*********************************************
* 將圖片流讀入字符數(shù)組中,并顯示到客戶端
********************************************/
try {
if (rs.next()) {
in = rs.getBinaryStream("photo");
response.reset(); //返回在流中被標記過的位置
response.setContentType("image/jpg"); //或gif等
// int len=in.available();//得到文件大小
OutputStream toClient = response.getOutputStream();
byte[] P_Buf = new byte[len];
int i;
while ((i = in.read(P_Buf)) != -1) {
toClient.write(P_Buf, 0, i);
}
in.close();
toClient.flush(); //強制清出緩沖區(qū)\\r
toClient.close();
} else {
M_EorrMenage = "無此圖片!";
M_EorrMenage =
new String(M_EorrMenage.getBytes("ISO8859_1"), "GBK");
response.setContentType("text/html; charset=gb2312");
out.println("<html>");
out.println(
"<head><title>this photo isn\'t have</title></head>");
out.println("<body>");
out.println("<p>" + M_EorrMenage + "</p>");
out.println("</body></html>");
}
rs.close();
} catch (Exception e) {
e.printStackTrace();
M_EorrMenage = "無法讀取圖片!";
M_EorrMenage =
new String(M_EorrMenage.getBytes("ISO8859_1"), "GBK");
response.setContentType("text/html; charset=gb2312");
out.println("<%@ page contentType=\'text/html; charset=gb2312\' %>");
out.println("<html>");
out.println("<head><title>no photo</title></head>");
out.println("<body>");
out.println("<p>" + M_EorrMenage + "</p>");
out.println("</body></html>");
}
}
//Clean up resources
public void destroy() {
try {
conn.close();
} catch (SQLException e) {
System.err.println("aq.executeUpdate:" + e.getMessage());
M_EorrMenage = "對不起,數(shù)據(jù)庫無法完成此操作!";
}
}
}
<!---------------------------顯示---------------------------------------------->
<html>
<head>
<title>Untitled Document</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
<table>
<%
int i=1;
while(i<3){
%>
<tr>
<td colspan="3"> <img border="1" src="http://192.168.1.50:8100/ShowImage?photoid=<%=i%>"></td>
</tr>
<%
i++;
}
%>
</table>
</body>
</html>
posted @
2006-11-21 19:54 選寶網(wǎng)an9 閱讀(624) |
評論 (0) |
編輯 收藏
(轉(zhuǎn)載)這個是DBunit的問題,1.8以上的版本才有這個問題!
只要修改User.java
/**
???? * @return Returns the enabled.
???? * @hibernate.property column="enabled"?
???? */
??? public Boolean getEnabled() {
??????? // isEnabled doesnt' work for copying properties to Struts ActionForms
??????? return enabled;
??? }
修改成
/**
???? * @return Returns the enabled.
???? * @hibernate.property column="enabled"
type="yes_no"???? */
??? public Boolean getEnabled() {
??????? // isEnabled doesnt' work for copying properties to Struts ActionForms
??????? return enabled;
??? }
就加了這一點,就可以了,
其實 type="yes_no" hibernate會映射成CHAR(1) , 而type="boolean" 它會映射成BIT , 估計dbunit在插入sample-data.xml的時候會出錯。
posted @
2006-10-26 14:15 選寶網(wǎng)an9 閱讀(339) |
評論 (0) |
編輯 收藏
解決此問題,應該這樣寫:
window.location.href=window.location.href;
window.location.reload;
同理,如果是刷新父窗口,應該這樣寫:
window.opener.location.href=window.opener.location.href;
window.location.reload;
這種寫法就不出現(xiàn)那討厭的對話框啦!
posted @
2006-10-23 13:43 選寶網(wǎng)an9 閱讀(279) |
評論 (0) |
編輯 收藏
<script defer>
function SetPrintSettings() {
// -- advanced features
factory.printing.SetMarginMeasure(2) // measure margins in inches
factory.SetPageRange(false, 1, 3) // need pages from 1 to 3
factory.printing.printer = "HP DeskJet 870C"
factory.printing.copies = 2
factory.printing.collate = true
factory.printing.paperSize = "A4"
factory.printing.paperSource = "Manual feed"
// -- basic features
factory.printing.header = "This is MeadCo"
factory.printing.footer = "Advanced Printing by ScriptX"
factory.printing.portrait = false
factory.printing.leftMargin = 1.0
factory.printing.topMargin = 1.0
factory.printing.rightMargin = 1.0
factory.printing.bottomMargin = 1.0
}
</script>
<script language="javascript">
function printsetup(){
// 打印頁面設置
wb.execwb(8,1);
}
function printpreview(){
// 打印頁面預覽
document.getElementById('button1').style.display='none';
document.getElementById('button2').style.display='none';
document.getElementById('button3').style.display='none';
document.getElementById('button4').style.display='none';
wb.execwb(7,1);
location.reload();
}
function printit()
{
if (confirm('確定打印嗎?')) {
wb.execwb(6,6)
}
}
</script>
</head>
<body>
??? <OBJECT classid="CLSID:8856F961-340A-11D0-A96B-00C04FD705A2" height=0 id=wb name=wb width=0></OBJECT>
??? <input type=button name=button_print value="打印" onclick="printit()" id="button1">
??? <input type=button name=button_setup value="打印頁面設置" onclick="printsetup();" id="button2">
??? <input type=button name=button_show value="打印預覽" onclick="printpreview();" id="button3">
??? <input type=button name=button_fh value="關閉" onclick="javascript:window.close();" id="button4">
??? <TABLE width="90%" cellspacing="0" bordercolordark="#CEDAE7" cellpadding="1" align="center" bordercolorlight="#155BBD" border="1">
??????? <TBODY>
??????? <THEAD style="display:table-header-group;font-weight:bold">
??????????? <TR>
??????????????? <TD width=73 rowspan="2" align="center">
??????????????????? 專家姓名
??????????????? </TD>
??????????????? <TD height="31" colspan="4" align="center">
??????????????????? 次數(shù)
??????????????? </TD>
??????????? </TR>
??????????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=25 onMouseOut="this.bgColor='#CEE5FF'" bgColor=#f2fff4>
??????????????? <TD width="147" height=25 bgcolor="#94C0F1" align="center">
??????????????????? 正常參加
??????????????? </TD>
??????????????? <TD width="108" height=25 bgcolor="#94C0F1" align="center">
??????????????????? 拒絕參加
??????????????? </TD>
??????????????? <TD width="124" height=25 bgcolor="#94C0F1" align="center">
??????????????????? 未通知
??????????????? </TD>
??????????????? <TD width="88" height=25 bgcolor="#94C0F1" align="center">
??????????????????? 總數(shù)
??????????????? </TD>
??????????? </TR>
??????? </THEAD>
??????? <!-- 所有專家 -->
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000020';" onMouseOut="this.bgColor='#FfffFF'" bgColor=#ffffff>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fsdfs
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000022';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? ggafds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000029';" onMouseOut="this.bgColor='#FfffFF'" bgColor=#ffffff>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? 王五
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000050';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? 余敏
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000061';" onMouseOut="this.bgColor='#FfffFF'" bgColor=#ffffff>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? 江澤民
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000064';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? 袁平1
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000093';" onMouseOut="this.bgColor='#FfffFF'" bgColor=#ffffff>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? zzz
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
?
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000112';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? 冶金專家1
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
?
??????????????? <font color='red'>1</font>
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
?
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000113';" onMouseOut="this.bgColor='#FfffFF'" bgColor=#ffffff>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? 冶金專家2
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? <font color='red'>1</font>
?
?
?
??????????? </TD>
??????? </TR>
?
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <TR onMouseOver="this.bgColor='#94C0F1'" style="CURSOR: hand" height=22 onclick="location='expertInfo.do?exp_id=EP00000002';" onMouseOut="this.bgColor='#CEE5FF'" bgColor=#DAE5F9>
??????????? <TD>
??????????????? <DIV align=center>
??????????????????? fds
??????????????? </DIV>
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
??????????? </TD>
??????????? <TD align=center>
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
?
?
?
?
?
?
?
?
?
??????????????? 0
??????????? </TD>
??????????? <TD align=center>
??????????????? <font color='red'>1</font>
?
?
?
?
?
?
?
?
?
?
?
?
??????????? </TD>
??????? </TR>
??????? <!-- 正常參加專家 -->
??????? <!-- 拒絕專家 -->
??????? </TBODY>
??????? <TFOOT style="display:table-footer-group;font-weight:bold">
??????????? <TR>
??????????????? <TD colspan="2" align="center" style="font-weight:bold;border:3px double blue">
??????????????????? 每頁都有的表尾
??????????????? </TD>
??????????? </TR>
??????? </TFOOT>
??? </TABLE>
</body>
?
posted @
2006-10-13 12:39 選寶網(wǎng)an9 閱讀(308) |
評論 (0) |
編輯 收藏