Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

JSP·ÖÒ³¼¼Êõ

ÔÚʹÓÃÊý¾Ý¿âµÄ¹ý³ÌÖУ¬²»¿É±ÜÃâµÄÐèҪʹÓõ½·ÖÒ³µÄ¹¦ÄÜ£¬¿ÉÊÇJDBCµÄ¹æ·¶¶Ô´ËȴûÓкܺõĽâ¾ö¡£¶ÔÓÚÕâ¸öÐèÇóºÜ¶àÅóÓѶ¼ÓÐ×Ô¼ºµÄ½â¾ö·½°¸£¬±ÈÈçʹÓÃVectorµÈ¼¯ºÏÀàÏȱ£´æÈ¡³öµÄÊý¾ÝÔÙ·ÖÒ³¡£µ«ÕâÖÖ·½·¨µÄ¿ÉÓÃÐԺܲÓëJDBC±¾ÉíµÄ½Ó¿ÚÍêÈ«²»Í¬£¬¶Ô²»Í¬ÀàÐ͵Ä×ֶεÄÖ§³ÖÒ²²»ºÃ¡£ÕâÀïÌṩÁËÒ»ÖÖÓëJDBC¼æÈÝÐԷdz£ºÃµÄ·½°¸¡£
JDBCºÍ·ÖÒ³
¡¡¡¡SunµÄJDBC¹æ·¶µÄÖƶ¨£¬ÓÐʱºÜÈÃÈË¿ÞЦ²»µÃ£¬ÔÚJDBC1.0ÖУ¬¶ÔÓÚÒ»¸ö½á¹û¼¯£¨ResultSet£©ÄãÉõÖÁÖ»ÄÜÖ´ÐÐnext()²Ù×÷£¬¶øÎÞ·¨ÈÃÆäÏòºó¹ö¶¯£¬Õâ¾ÍÖ±½Óµ¼ÖÂÔÚÖ»Ö´ÐÐÒ»´ÎSQL²éѯµÄÇé¿öÏÂÎÞ·¨»ñµÃ½á¹û¼¯µÄ´óС¡£ËùÒÔ£¬Èç¹ûÄãʹÓõÄÊÇJDBC1.0µÄÇý¶¯£¬ÄÇôÊǼ¸ºõÎÞ·¨ÊµÏÖ·ÖÒ³µÄ¡£
¡¡¡¡ºÃÔÚSunµÄJDBC2¹æ·¶ÖкܺõÄÃÖ²¹ÁËÕâÒ»¸ö²»×㣬Ôö¼ÓÁ˽á¹û¼¯µÄÇ°ºó¹ö¶¯²Ù×÷£¬ËäÈ»ÈÔÈ»²»ÄÜÖ±½ÓÖ§³Ö·ÖÒ³£¬µ«ÎÒÃÇÒѾ­¿ÉÒÔÔÚÕâ¸ö»ù´¡ÉÏд³ö×Ô¼ºµÄ¿ÉÖ§³Ö·ÖÒ³µÄResultSetÁË¡£
ºÍ¾ßÌåÊý¾Ý¿âÏà¹ØµÄʵÏÖ·½·¨
¡¡¡¡ÓÐһЩÊý¾Ý¿â£¬ÈçMySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ), Oracle(´óÐÍÍøÕ¾Êý¾Ý¿âƽ̨)µÈÓÐ×Ô¼ºµÄ·ÖÒ³·½·¨£¬±ÈÈçMySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)¿ÉÒÔʹÓÃlimit×Ӿ䣬Oracle(´óÐÍÍøÕ¾Êý¾Ý¿âƽ̨)¿ÉÒÔʹÓÃROWNUMÀ´ÏÞÖƽá¹û¼¯µÄ´óСºÍÆðʼλÖá£ÕâÀïÒÔMySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)ΪÀý£¬ÆäµäÐÍ´úÂëÈçÏ£º
     // ¼ÆËã×ܵļǼÌõÊý
     String SQL = "SELECT Count(*) AS total " + this.QueryPart;
     rs = db.executeQuery(SQL);    
     if (rs.next())
     Total = rs.getInt(1);     
     // ÉèÖõ±Ç°Ò³ÊýºÍ×ÜÒ³Êý
     TPages = (int)Math.ceil((double)this.Total/this.MaxLine);
     CPages = (int)Math.floor((double)Offset/this.MaxLine+1);
     // ¸ù¾ÝÌõ¼þÅжϣ¬È¡³öËùÐè¼Ç¼
     if (Total > 0) {
       SQL = Query + " LIMIT " + Offset + " , " + MaxLine;
       rs = db.executeQuery(SQL);       
     }    
     return rs;
   }  
¡¡¡¡º


Ïà¹ØÎĵµ£º

jsp ÂÒÂëÎÊÌâ

a.jspÒ³ÃæÄÚÈÝ£º
%26lt;%@ page language£½"java" import£½"java.util." pageEncoding£½"GB2312"%%26gt;%26lt;form action£½"b.jsp"%26gt; name£º%26lt;input type£½text name£½name%26gt; %26lt;input type£½submit%26gt;%26lt;/form%26gt;
b.jspÒ³ÃæÄÚÈÝ£º
%26lt;%@ page language£½"java" import£½"java.util." pageE ......

JSPÖÐincludeÖ¸ÁîºÍincludeÐÐΪµÄÇø±ð

 ÎÒÃǶ¼ÖªµÀÔÚjspÖÐincludeÓÐÁ½ÖÖÐÎʽ,·Ö±ðÊÇ
< %@ include file=” ”%>
< jsp:include page=” ” flush=”true”/>
¡¡¡¡Ç°ÕßÊÇÖ¸ÁîÔªËØ¡¢ºóÕßÊÇÐÐΪԪËØ¡£¾ßÌåËüÃǽ«Ôںδ¦Óã¿ÈçºÎÓü°ËüÃÇÓÐʲôÇø±ð£¿ÕâÓ¦¸ÃÊǺܶàÈË¿´µ½Ëü¶¼»áÏëµ½µÄÎÊÌâ¡£ÏÂÃæÒ»ÆðÀ´¿´¿´°É¡£
¡¡¡ ......

checkbox ÔÚjspÖеÄʹÓÃ

 ±¾ÎÄ×÷ÕߣºØýÃû
ËùÊô·ÖÀࣺÍøÂç±à³Ì
¼ÓÈëʱ¼ä£º2006-1-19
µã»÷´ÎÊý£º396
<%@ page language="java" contentType="text/html" %>
<%@ page import="com.ora.jsp.util.*" %>
<html>
<body bgcolor="white">
<form action="checkbox.jsp">
<input type="checkbox" name="fr ......

JSPÓï·¨Ïê½â11ÔÂ17ÈÕ[תÌû]

                               JSPÓï·¨Ïê½â[תÌû]
HTML×¢ÊÍ:
  1) ¿ÉÒÔÓÃ×¢ÊÍÄÚÈÝ,Ò²¿ÉÒÔÓñí´ïʽ.
  2)Òþ²Ø×¢ÊÍ:
  ×¢Êͻᱠ......

asp jsp´úÂë

 Ì½Ë÷Èí¼þ¹¤×÷ÊÒ³¤ÆÚרҵ³Ð½ÓÖÐСÐÍÉÌÒµÈí¼þ»òÍøÕ¾£¬×îÓŻݵļ۸ñºÍ¸ßÖÊÁ¿µÄ·þÎñÆÚ´ýÄúµÄ»Ý¹Ë£¡
±¾¹¤×÷ÊÒ³Ð½Ó JSP ASP  VB  PB  LotusNotes µÈÓïÑÔÒªÇóµÄÓ¦ÓÃϵͳ¿ª·¢ÒµÎñ
java jspʵսԴ³ÌÐò´úÂë:
                ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ