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

jspÖÐʹÓÃjavabeanµÄÁ½µã×¢ÒâÊÂÏî

jspÖÐʹÓÃjavabeanµÄÁ½µã×¢ÒâÊÂÏî
Ê×ÏÈÒ»µã£ºjavabeanÒ»¶¨Òª·ÅÔÚÃüÃû°üÀ²»ÄÜ·ÅÔÚĬÈÏ°üÀҲ¾ÍÊÇÔÚbeanÎļþµÄ¿ªÍ·Òªpackage¡¡pname;ÁË£¬Èç¹û²»·ÅÔÚÃüÃû°üÀï¶ø·ÅÔÚÁËĬÈÏ°üÀ×îºó½«±¨ÈçÏÂÕâÑùµÄ´íÎó£º
org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: 18 in the jsp file: /javabean.jsp
TempBean cannot be resolved to a type
Õâ¸öÔ­ÒòÆð³õÎÒÒ²ºÜ²»½â£¬ºóÀ´ÔÚÍøÉϲéÀ´²éÈ¥²ÅÖªµÀ£¬javaÏÖÔÚÒѾ­²»ÔÊÐíÃüÃû°üÀïµÄÀàµ÷ÓÃĬÈÏ°üÀïµÄÀàÁË£¬Ò²²»ÔÊÐíÔÚÃüÃû°üÀïʹÓÃimport classname(Õâ¸öÊÇĬÈÏ°üÀïµÄÀà)À´ÒýÓÃĬÈÏ°üÀïµÄÀàÁË£¬ËùÒԲŻá³öÏÖÒÔÉÏÎÊÌâ¡£ÄÃtomcatÀ´Ëµ£¬ËüÊÇÏȽ«jspÎļþת»»³ÉjavaÎļþ£¬È» ºóÔÙ½«Æä±àÒë³ÉclassÎļþÀ´Ê¹Ó㬵«ÊÇtomcatת»»³ÉµÄjavaÎļþÊǶ¨ÒåÔÚÒ»¸ö°üÀïµÄ£¬Õâ¸ö¿ÉÒÔÔÚtomcatµÄworkĿ¼ÖеÄjavaÎļþ Öп´µ½£¬ËùÒÔÈç¹ûjavabean·ÅÔÚĬÈÏ°üÀïµÄ»°£¬ÒòΪjava±¾ÉíµÄÓïÑԹ淶¶¨Ò壬jspÉú³ÉµÄjavaÎļþ¾ÍÎÞ·¨Ê¹ÓÃjavabeanÁË¡£ÎÒ¾õµÃÒ² ÓÉ´Ë¿ÉÒԵóö£¬ÔÚjspÍøÒ³ÖÐÒÔ¸÷ÖÖÐÎʽÀ´Ê¹Ó÷ÅÔÚĬÈÏ°üÀïµÄjavaÀ࣬¶¼¿ÉÄÜ»áÒýÆð±àÒë´íÎó£¬ËùÒÔÔÚjspÏîÄ¿ÖУ¬ËùÓеÄÀàÓ¦¸Ã¶¼·Åµ½×Ô¼ºÏàÓ¦µÄ°ü À²»ÒªÊ¹ÓÃĬÈÏ°ü¡£µ«ÊÇÕâÀïÒ²ÓÐÒ»¸ö±È½Ï¹îÒìµÄÎÊÌ⣬ËäÈ»°´JAVA¹æ·¶ËµµÄÊÇÄÇÑù£¬µ«ÊÇÈç¹ûÔÚjspÍøÒ³ÖÐʹÓÃÁËĬÈÏ°üµÄÀֻ࣬Ҫ°ÑËüÓõ½µÄĬÈÏ°üµÄ classÎļþ¿¼µ½tomcatµÄworkĿ¼ÖеÄÏàÓ¦Îļþ¼ÐÏ£¬¾Í²»»á·¢ÉúÉÏÃæËù˵µÄ±àÒë´íÎó¶øÄÜÕý³£ÔËÐУ¬ÖÁÓÚÔ­ÒòÊÇʲôÎÒÒ²¸ã²»¶®£¬²»Ì«Çå³þ tomcat¶ÔÀàµÄËÑÑ°»úÖÆ¡£·´ÕýΪÁËÈ·±£²»³ö´íÎ󣬻¹ÊÇ°ÑÀà·ÅÔÚÃüÃû°üÖУ¬²»ÒªÊ¹ÓÃĬÈÏ°ü¾ÍºÃ¡£
µÚ¶þµã£¬Õâ¸ö¿ÉÄÜÒ²¾ÍÊÇÎÒÕâÖÖ±¿µ°Åöµ½ÁË£¬¾ÍÊÇÔÚʹÓÃjsp:setProperty£¬jsp:getPropertyÕâÑùµÄ±êÇ©µÄʱºò£¬ËüµÄ propertyÊôÐÔÒ»¶¨ÒªÓÃСд£¬²»¹ÜjavabeanÀïµÄÊôÐÔÃûµÄ´óСдÈçºÎ£¬ÕâÀïÒ»¶¨ÒªÐ´Ð¡Ð´£¬²»È»¾Í±¨Ê²Ã´Cannot find any information on property 'Msg' in a bean of type 'test.TestBean'Ö®ÀàµÄ´íÎó¡£
ÖÁÓÚÆäËûµÄ»ù±¾ÉϾÍÊDZê×¼µÄjavabeanʹÓÃÁË£¬Ê²Ã´ÒªÓй«¹²Î޲εĹ¹Ô캯Êý£¬»¹Óи÷¸öÊôÐÔÒªÓÐset/get·½·¨£¬»¹ÓÐjavabeanÒªÊÇÒ»¸öpublicÀà¡£¾ÍÕâЩ°É£¡°¦£¬Í·ÌÛ£¡


Ïà¹ØÎĵµ£º

jspÂÒÂë½â¾ö

jspÂÒÂë½â¾ö(תÔØ)
jspÂÒÂë½â¾ö(תÔØ)
JAVA֪ʶ   2009-04-14 08:49   ÔĶÁ935   ÆÀÂÛ5  
GBK±àÂë
GBK±àÂëÊÇÖйúÖƶ©µÄ¡¢µÈͬÓÚUCSµÄеÄÖÐÎıàÂëÀ©Õ¹¹ú¼Ò±ê×¼¡£GBK¹¤×÷С×éÓÚ1995Äê10Ô£¬Í¬Äê12ÔÂÍê³ÉGBK¹æ·¶¡£¸Ã±àÂë±ê×¼¼æÈÝGB2312£¬¹²ÊÕ¼ºº×Ö21003¸ö¡¢·ûºÅ883¸ö£¬²¢Ìṩ1 ......

JSP ×é¼þÉÏ´«Îļþ£¨common fileupload£©

µÚ1¸öÉÏ´«×é¼þcommons-fileupload
=============commons-fileupload ================
common-fileupload×é¼þÊÇapacheµÄÒ»¸ö¿ªÔ´ÏîÄ¿Ö®Ò»£¬¿ÉÒÔ´Óhttp://jakarta.apache.org/commons/fileupload/ÏÂÔØ¡£¸Ã×é¼þ¼òµ¥Ò×Ó㬿ÉʵÏÖÒ»´ÎÉÏ´«Ò»¸ö»ò¶à¸öÎļþ£¬²¢¿ÉÏÞÖÆÎļþ´óС¡£
-ÏÂÔغó½âѹzip°ü£¬½«commons-fileupload-1.1. ......

JSP»ù´¡

Ò»¡¢JSP¼ò½é
JSP (Java Server Pages)ÊÇ·þÎñÆ÷¶ËµÄ½Å±¾ÓïÑÔ£¬ÊÇÒ»ÖÖÔÚHTMLÒ³ÃæÖмÓÈëJavaÓïÑÔ¶øÉú³É¶¯Ì¬Ò³ÃæµÄ¼¼Êõ£º¼ÓÈëÁËеıêÇ©£¨<%£¬%>£¬…£©¡£
JSPÊÇÒÔJavaºÍServletΪ»ù´¡¿ª·¢¶ø³ÉµÄ¶¯Ì¬ÍøÒ³Éú³É¼¼Êõ£¬ËüµÄµ×²ãʵÏÖÊÇJava Servlet¡£
JSPÒ³ÃæÓÉHTML´úÂëºÍǶÈëÆäÖеÄJava´úÂëËù×é³É¡£·þÎñÆ÷ÔÚÒ³Ãæ±»¿Í» ......

JSP¾Å´óÄÚÖöÔÏó¼°Ëĸö×÷ÓÃÓò

¾Å´ó¶ÔÏó£º
ÄÚÖöÔÏó£¨ÓÖ½ÐÒþº¬¶ÔÏó£¬ÓÐ9¸öÄÚÖöÔÏó£©:²»ÐèÒªÔ¤ÏÈÉùÃ÷¾Í¿ÉÒÔÔڽű¾´úÂëºÍ±í´ïʽÖÐËæÒâʹÓÃ
1-out:
javax.servlet.jsp.JspWriterÀàÐÍ£¬´ú±íÊä³öÁ÷µÄ¶ÔÏó¡£×÷ÓÃÓòΪpage£¨Ò³ÃæÖ´ÐÐÆÚ£©
request£ºjavax.servlet.ServletRequestµÄ×ÓÀàÐÍ£¬´Ë¶ÔÏó·â×°ÁËÓÉWEBä¯ÀÀÆ÷»òÆäËü¿Í»§¶ËÉú³ÉµØHTTP
ÇëÇóµÄϸ½Ú£¨²ÎÊý ......

resin·þÎñÆ÷ÖÐͨ¹ýSSI°üº¬JSPÒ³Ãæ

1¡¢Ò»¡¢ÏÈÌáÌõ¼þ£º ÔÚweb.xmlÖмÓÒÔÏÂÓï¾ä£¨Ô­Òò²Î¿¼RESIN¹Ù·½Îĵµ£©    
<servlet>
         <servlet-name>SSIServlet</servlet-name>
        <servlet-class>com.caucho.servlets.ssi.SS ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ