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

JSPÖÐÀûÓÃÊý¾ÝÔ´¶ÔÏó½¨Á¢Êý¾Ý¿âÁ¬½Ó

ÅäÖóÌÐòµÄÔËÐÐĿ¼ÓëJDBCÊý¾ÝÔ´:
<Context path="/test" docBase="F:\JSPLesson\test" reloadable="true">
    <Resource name="jdbc/bookstore" auth="Container" type="javax.sql.DataSource"
              maxActive="100" maxIdle="30" maxWait="10000"
              username="root" password="123456"
              driverClassName="com.mysql.jdbc.Driver"
              url="jdbc:mysql://localhost:3306/bookstore?autoReconnect=true"/>
</Context>
JSPÖÐͨ¹ýÈçÏ·½Ê½µÃµ½Êý¾Ý¿âÁ¬½Ó:
<%
Context ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/bookstore");
Connection conn = ds.getConnection();
%>


Ïà¹ØÎĵµ£º

JSPȨÏÞ¿ØÖÆ£¨¶þ£©

1 £©Ê×ÏȽ¨Á¢¹ÜÀíÓû§±í£¬ÆäÖÐ UserPopedom ¼Ç¼Óû§µÄȨÏÞ×Ö·û£¬ÆäʵҲ¾ÍÊÇһЩ JSP »òÕß ACTION µÄÎļþÃû£º
CREATE TABLE [dbo].[AdminUser] (
  [UserID] [varchar] (50) COLLATE Chinese_PRC_CI_AS NULL ,
  [UserName] [varchar] (50) COLLATE Chinese_PRC_CI_AS NULL ,
  [UserPass] [varchar ......

ÔÚjspÖÐʹÓÃsmartupload×é¼þÉÏ´«Îļþ

 
ÔÚjspÖÐʹÓÃsmartupload×é¼þÉÏ´«Îļþ
   jsp¶ÔÉÏ´«ÎļþµÄÖ§³Ö²»ÏóphpÖÐÖ§³ÖµÄÄÇôºÃ£¬Ö±½Ó×ö³ÉÁ˺¯Êý£¬Ò²²»ÏóaspÖÐҪͨ¹ý×é¼þ²ÅÄÜʵÏÖ¡£jspÖпÉÒÔͨ¹ýjavabeanÀ´ÊµÏÖ¡£µ«ÊÇÎÒÃÇûÓбØÒª×Ô¼ºÈ¥Ð´Ò»¸öÉÏÔØµÄbean£¬ÔÚÍøÉÏÒѾ­ÓÐÁ˺ܶà³ÉÐ͵ļ¼Êõ£¬smartupload¾ÍÊÇÆäÖеÄÒ»¸ö¡£µ«ÊÇsmartuploadÊǽ«ÎļþÏȶÁµ ......

½â¾öjsp»òserverlet ²»ÄܽâÎömultipart/form

½â¾öjsp»òserverlet ²»ÄܽâÎömultipart/form-data ÀàÐÍµÄ±íµ¥ÓòµÄÎÊÌâ
10 6ÔÂ 2008
Situation:
Javax.servlet.HttpServletRequest.getParameter(String) returns null when the ContentType is multipart/form-data
Solutions:
Solution A:
1. download http://www.servlets.com/cos/index.html
2. invoke getPara ......

jspÂÒÂëÎÊÌâ URL´«ÖµÂÒÂëÎÊÌâ

 jspÂÒÂëÎÊÌâ½â¾ö
1¡¢Ò»°ãµÄjspÒ³ÃæÏÔʾÂÒÂë
   <%@ page contentType="text/html; charset=UTF-8"%>
   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
2¡¢±íµ¥Ìá½»ÖÐÎÄʱ³öÏÖÂÒÂë
Èç¹ûjspÌá½»Ó¢ÎÄ×Ö·ûÄÜÕýÈ·ÏÔʾ£¬¶øÌá½»ÖÐÎÄʱ¾Í»á³öÏÖÂÒÂë¡£
Ô­Òò£ºä ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ