jspÖжÁÈ¡propertiesÎļþ
jspÖжÁÈ¡propertiesÎļþ£¬²¢°ÑÖµÉèµ½js±äÁ¿ÖУº
web_stderr.propertiesÎļþÄÚÈÝ£º
common.username.error.null = UserName can not be null.
common.username.error.invalid = UserName is invalid.
common.password.error.null = Password can not bu null.
common.password.error.invalid = Password is invalid.
common.login.error.user = The user can not been stored or password is wrong.
common.request.parameter.error = Request parameter error.
common.function.title.null = The tilte of function or is null.
common.session.timeout = The session has already expired.Please login again.
1.´æ´¢propertiesÎļþÄÚÈݵÄjs±äÁ¿(common-checkmessage.jsp)£º
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8" import="java.util.ResourceBundle"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title></title>
<%ResourceBundle res = ResourceBundle.getBundle("web_stderr"); %>
<mce:script type="text/javascript"><!--
var check_message_username_null = '<%=res.getString("common.username.error.null")%>';
var check_message_username_invalid = '<%=res.getString("common.username.error.invalid")%>';
var check_message_password_null = '<%=res.getString("common.password.error.null")%>';
var check_message_password_invalid = '<%=res.getString("common.password.error.invalid")%>';
// --></mce:script>
</head>
<body>
</body>
</html>
´ËʱֻҪÔÚÆäËûjspÖаüº¬¸ÃjspÎļþ£¬¾Í¿ÉÒÔÔÚjspºÍjsÎļþÖÐʹÓÃÕâЩ±äÁ¿¡£
Ïà¹ØÎĵµ£º
<%@ page contentType="image/jpeg" import="java.awt.*,java.awt.image.*,java.util.*,javax.imageio.*" %>
<%!
Color getRandColor(int fc,int bc){//¸ø¶¨·¶Î§»ñµÃËæ»úÑÕÉ«
Random random = new Random();
if(fc>255) fc=255;
if(bc>255) bc=255;
int r=fc+random.nextInt(bc-fc);
int g=fc+ran ......
ÕªÒª£ºËäÈ»session»úÖÆÔÚwebÓ¦ÓóÌÐòÖб»²ÉÓÃÒѾºÜ³¤Ê±¼äÁË£¬µ«ÊÇÈÔÈ»ÓкܶàÈ˲»Çå³þsession»úÖÆµÄ±¾ÖÊ£¬ÒÔÖÁ²»ÄÜÕýÈ·µÄÓ¦ÓÃÕâÒ»¼¼Êõ¡£±¾ÎĽ«ÏêϸÌÖÂÛsessionµÄ¹¤×÷»úÖÆ²¢ÇÒ¶ÔÔÚJava web applicationÖÐÓ¦ÓÃsession»úÖÆÊ±³£¼ûµÄÎÊÌâ×÷³ö½â´ð¡£
Ŀ¼£º
Ò»¡¢ÊõÓïsession
¶þ¡¢HTTPÐÒéÓë״̬±£³Ö
Èý¡¢Àí½âcookie» ......
¾Å´ó¶ÔÏó£º
ÄÚÖöÔÏó£¨ÓÖ½ÐÒþº¬¶ÔÏó£¬ÓÐ9¸öÄÚÖöÔÏó£©:²»ÐèÒªÔ¤ÏÈÉùÃ÷¾Í¿ÉÒÔÔڽű¾´úÂëºÍ±í´ïʽÖÐËæÒâʹÓÃ
1-out:
javax.servlet.jsp.JspWriterÀàÐÍ£¬´ú±íÊä³öÁ÷µÄ¶ÔÏó¡£×÷ÓÃÓòΪpage£¨Ò³ÃæÖ´ÐÐÆÚ£©
request£ºjavax.servlet.ServletRequestµÄ×ÓÀàÐÍ£¬´Ë¶ÔÏó·â×°ÁËÓÉWEBä¯ÀÀÆ÷»òÆäËü¿Í»§¶ËÉú³ÉµØHTTP
ÇëÇóµÄϸ½Ú ......
1£¬Ð½¨Ò»web¹¤³Ì£¬½«Êý¾Ý¿âÁ¬½Ó°üÌí¼ÓÈëlibÎļþ¼ÐÏ¡£
2£¬Ð½¨jspÒ³Ãæ£¬ÄÚÈÝÈçÏ£º
<%@ page language="java" import="java.util.*" import="java.sql.*" pageEncoding="gb2312"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+re ......
javaµ¼Èëµ¼³öexcel²Ù×÷(jxl)£¨1£©
¹Ø¼ü×Ö: javaµ¼Èëµ¼³öexcel²Ù×÷(jxl)£¨1£©
jxl.jar °ü
ÏÂÔØµØÖ·:
http://www.andykhan.com/jexcelapi/
ÕæÊµÏÂÔØµØÖ·:
http://www.andykhan.com/jexcelapi/download.html
ÍøÕ¾É϶ÔËüµÄÌØÕ÷ÓÐÈçÏÂÃèÊö£º
¡ñ Ö§³ÖExcel 95-2000µÄËùÓа汾
¡ñ Éú³ÉExcel 2000±ê×¼¸ñʽ
¡ñ Ö§³Ö×ÖÌå¡¢ ......