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

JSPÖÐÉú³É¶¯Ì¬XMLʵÀý

<?xml version="1.0" encoding="gb2312" ?>
<?xml-stylesheet type="tet/css" href="mystyle.css" ?>
<%@ page errorPage="error.jap" %>
<%@ page contentType="text/xml" %>
<realmarid>
»ÊÂí»¨Ãû²á
<athlete>
<name>Æë´ïÄÚ</name>
<country>·¨¹ú</country>
<age>32</age>
<telephone>124252432</telephone>
<date>The date is <%=new java.util.Date()%></date>
</athlete>
<athlete>
<name>ÀͶû</name>
<country>Î÷°àÑÀ</country>
<age>28</age>
<telephone>1243432</telephone>
<date>The date is <%=new java.util.Date()%></date>
</athlete>
<athlete>
<name>±´¿ËººÄ·</name>
<country>Ó¢¹ú</country>
<age>28</age>
<telephone>1243432</telephone>
<date>The date is <%=new java.util.Date()%></date>
</athlete>
</realmarid>
µÚÒ»ÐУºXMLÉùÃ÷£»
µÚ¶þÐУºÎªXMLÎļþµÄÓ¦ÓóÌÐòÌṩÐÅÏ¢£¬Type±íÃ÷ÏÔʾµÄ·½Ê½£¬XML¿ÉÒÔʹÓÃCSSºÍXSLÁ½ÖÖ·½Ê½ÏÔʾ£¬´Ë´¦±êÃ÷ʹÓÃCSSÀ´ÏÔʾ£»
Href±íÃ÷ÁËCSSÎļþµÄÏà¶Ô·¾¶£¬ÕâÀïcssÎļþºÍjspÎļþÔÚͬһ¸öĿ¼Ï£»
½ÓÏÂÀ´ÊÇJSPÖеÄpageÖ¸ÁpageÖ¸ÁîÌṩJSPÒ³ÃæµÄÊôÐÔ£¬pageÖ¸ÁîÖж¨ÒåµÄÊôÐÔÊÊÓÃÓÚ¸ÃJSPÒ³Ãæ£¬ÒÔ¼°ËùÓаüº¬µÄ¾²Ì¬Îļþ£»
 pageÖ¸ÁîµÄ¸ñʽ£º<@%page [attribute="value"]%>
 contentTypeÊôÐÔ±íÃ÷ÄÚÈÝÀàÐÍÐÅÏ¢£¬´Ë´¦Îªtext/xml£¬´Ë´¦ÊÇJSPÖÐÖ±½ÓÓ¦ÓÃXMLµÄ¹Ø¼üËùÔÚ£»
ÉÏÀýÖÐÓÐ<%=new java.util.Date()%>µÄÓï¾ä£¬ÊÇJSPÖаüº¬µÄJavaÓï¾ä£¬Õⲿ·ÖÉú³É¶¯Ì¬Ò³Ãæ
ÉÏÀýÖÐÔÚXMLÎĵµÄ£°åÖмÓÈëJSPÒ³Ãæ£¬ÔÚJSPÖмÓÈëJava´úÂ룬ÕâÑùXML¾Í¿ÉÒÔÓɾ²±ä¶¯£¬²úÉú¶¯Ì¬µÄÄÚÈÝ£¬Ò³ÃæÒ²¿ÉÒÔ±äµÃÃÀ¹ÛÉú¶¯£»
µ±XMLÎĵµÖеÄJSPÒ³Ãæ±»ÇëÇóʱ£¬Java´úÂ뽫ִÐУ¬JSP·þÎñÆ÷ÏȽ«JSPÍøÒ³±àÒë³ÉServlet£¬±àÒëʱJava´úÂ뽫»á±»Ö´ÐУ¬ÇÒÖ»Ðè·þÎñÆ÷µÚÒ»´ÎÖ´Ðм´¿É£¬¿Í»§¶ËÔÙÇëÇó¸ÃÒ³ÃæÊ±£¬»á½«µÚÒ»´ÎÖ´ÐеĽá¹û´«Ë͸ø¿Í»§¶Ë£¬´Ó¶ø´ó´óÌá¸ßÖ´ÐÐЧÂÊ¡£


Ïà¹ØÎĵµ£º

MyEclipse¸ü¸Äjsp±à¼­Ê±×ÖÌå

     Ò»Ö±ÒÔÀ´Ê¹ÓÃMyeclipse±à¼­Ê±£¬¸Ð¾õÔ­ÓеÄ×ÖÌå´óСºÜ²»ÊÊÓ¦£¬ÓÚÊÇÔÚÍøÉÏËÑÁ˹ØÓÚÔÚMyEclipseÖÐÔõÑùÐÞ¸Ä×ÖÌå´óС£¬ºÜ¶à¶¼ÊÇʹÓÃwindow-preferences-general-apperaence-colors and fonts-java-java edditor text font À´ÐÞ¸Ä×ÖÌå¡£
    ʹÓÃÕâ¸ö·½·¨ËäȻдÀàÎļþÀïÃæµÄ´óС¶¼¸ü¸ü¸ ......

tomcat¡¢JDKºÍJSPÅäÖÃ

¾­³£¿´µ½Ðí¶àÈËÎÊÈçºÎÅäÖÃJDKºÍJSP£¬ÏÖÔÚÎÒ°Ñ·½·¨×ܽáÏ£¬Ï£Íû¶Ô´ó¼ÒÓÐËù°ïÖú¡£
µÚÒ»²½£ºÏÂÔØjdkºÍtomcat
µÚ¶þ²½£º°²×°ºÍÅäÖÃÄãµÄjdkºÍtomcat£ºÖ´ÐÐjdkºÍtomcatµÄ°²×°³ÌÐò£¬È»ºóÉèÖð´ÕÕ·¾¶½øÐа²×°¼´¿É¡£
1.°²×°j2sdkÒÔºó£¬ÐèÒªÅäÖÃһϻ·¾³±äÁ¿£¬ÔÚÎҵĵçÄÔ->ÊôÐÔ->¸ß¼¶->»·¾³±äÁ¿->ϵͳ±äÁ¿ÖÐÌí¼ÓÒÔÏ»· ......

ͨ¹ýDataSet¶ÁÈ¡XMLµÄЧÂÊÎÊÌâ

Ò»Ö±ÒÔÀ´¶ÁÈ¡xml¶¼ÊÇͨ¹ýDataSetµÄReadXML·½·¨À´½â¾ö£¬ÆäËûÊôÐÔÒ²¶¼Ã»ÓÐʹÓá£ÔÚÊý¾ÝÁ¿Ð¡µÄʱºòµ¹Ò²Ïà°²ÎÞÊ£¬Ö±µ½½ñÌì¶Áȡһ¸ö20MµÄXMLÁ÷²Å·¢ÏÖʵÔÚ̫ӰÏìЧÂÊÁË¡£
ĬÈÏÇé¿öÏ£¬ReadXMLȱʡÇé¿öÏÂʹÓÃXmlReadMode.Auto·½Ê½¶ÁÈ¡£¬ÓÃÒÔǰµÄ×÷·¨£¬ÓÉÓÚxmlÎļþÀïûÓаüº¬Scheme,DataSet»áÏÈÍÆ¶ÏxmlµÄ½á¹¹£¬È»ºóÔÙ¼ÓÔØÊý¾Ý¡£¿É ......

XML DTDÏà¹ØµÄÄÚÈÝ

Ò»¸ö¶¨ÒåEmailµÄÀý×Ó
<?xml version="1.0">
<!DOCTYPE message[
   <!ELEMENT message(header,body,signature,footer)>  --¶¨ÒåÁËmessageµÄ×ÓÔªËØ
   <!ELEMENT header(date,from,to,subject,banner)>    --header»¹ÓÐ×ÓÔªËØ
   <!ELEMENT ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ