<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0">
<channel>
<title>
<![CDATA[IT Technology Topic]]></title>
 <link>
http://ljbedu.blogcn.com</link>
<description>
<![CDATA[null]]></description>
<managingEditor>
<![CDATA[hy2000l]]></managingEditor>
<dc:creator>
<![CDATA[hy2000l]]></dc:creator>
<blogcn_uid>
hy2000l</blogcn_uid>
<blogcn_hits>
279</blogcn_hits>
<item>
<blogcn_uid>
<![CDATA[9090865]]></blogcn_uid>
<title>
<![CDATA[Struts-config.xml配置文件讲解]]></title>
<link>
http://ljbedu.blogcn.com/diary,4430911.shtml</link>
<description>
<![CDATA[<P>&nbsp;&nbsp; struts-config.xml配置文件在struts是非常重要的，在这个文件里描述了所有的Struts组件。 <BR>在这里包括配置主要的组件及次要的组件，下面是struts-config.xml包含主要元素的内容： <BR>一、 struts-config.xml的主要元素： <BR>&lt;?xml version=”1.0” encoding=”ISO-8859-1”?&gt; <BR>&lt;!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 1.1//EN" <BR>"<A href="http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd</A>"&gt; <BR>&lt;struts-config&gt; <BR>&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp; &lt;data-sources&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;data-source&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/data-source&gt; <BR>&nbsp;&nbsp; &lt;/data-sources&gt; </P>
<P>&nbsp;&nbsp; &lt;form-beans&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;form-bean / &gt; <BR>&nbsp;&nbsp; &lt;/form-beans&gt; </P>
<P>&nbsp;&nbsp; &lt;global-forwards&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;forward / &gt; <BR>&nbsp;&nbsp; &lt;/global-forwards&gt; </P>
<P>&nbsp;&nbsp; &lt;action-mappings&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action / &gt; <BR>&nbsp;&nbsp; &lt;/action-mappings&gt;&nbsp;&nbsp; </P>
<P>&lt;controller / &gt; </P>
<P>&nbsp;&nbsp; &lt;message-resources / &gt; </P>
<P>&nbsp;&nbsp; &lt;plug-in /&gt; </P>
<P>&lt;/struts-config&gt; <BR>&nbsp;&nbsp;&nbsp; 注意：以上各元素的顺序是非常重要的，你的struts-config.xml配置文件必须按照这个顺序进行配置，否 </P>
<P>则在你的容器启动的时候就会出错。 </P>
<P>二、struts-config.xml的子元素： <BR>1．&lt;icon / &gt;子元素 <BR>&nbsp;&nbsp; 它包含&lt;small-icon / &gt;及&lt;large-icon / &gt;，它的作用是图形化其父元素， <BR>&lt;small-icon/&gt;的内容是一个16x16的图像文件，而&lt;large-icon/&gt;的内容是一个32x32的图像文件。如下例子： <BR>&nbsp;&nbsp; &lt;icon&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp; &lt;small-icon&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /images/smalllogo.gif <BR>&nbsp;&nbsp;&nbsp;&nbsp; &lt;/small-icon&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp; &lt;large-icon&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /images/largelogo.gif <BR>&nbsp;&nbsp;&nbsp;&nbsp; &lt;/large-icon&gt; <BR>&lt;/icon&gt; <BR>2．&lt;display-name / &gt;子元素 <BR>&nbsp;&nbsp; 它提供对父元素的短文字（short textual）描述信息，如下： <BR>&nbsp;&nbsp; &lt;display-name&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; short textual discription of its parent element <BR>&nbsp;&nbsp; &lt;/display-name&gt; <BR>3．&lt;description / &gt;子元素 <BR>&nbsp;&nbsp; 它提供对父元素的完全（full-length textual）的描述信息，如下： <BR>&nbsp; &lt;description&gt; <BR>&nbsp;&nbsp;&nbsp; full-length textual discription of its parent element <BR>&nbsp; &lt;/description&gt; <BR>4．&lt;set-property / &gt;子元素 <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 它用来设置它的父元素中设定的JavaBean的属性值，它一般用在指定的GenericDataSource 属性， <BR>扩展的ActionMappings以及扩展的 global forwards。如下： <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="name of bean property" value="value of bean property" /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 例如： <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="driverClass" value="org.gjt.mm.mysql.Driver" /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="user" value="admin"/&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="maxCount" value="4"/&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="minCount" value="2"/&gt;&nbsp; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="password" value=""/&gt;&nbsp; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property="url" value="jdbc:mysql://localhost:3306/struts"/&gt; </P>
<P>三、&nbsp;&nbsp;&nbsp; 配置JDBC数据源 <BR>其配置形式如下： <BR>&lt;data-sources&gt; <BR>&lt;data-source&gt; <BR>&lt;set-property property="driverClass" value="fully qualified path of JDBC driver"/&gt; <BR>&lt;set-property property="url" value="data source URL"/&gt; <BR>&lt;set-property property=”mincount” value="the minimum number of connections to open"/&gt; <BR>&lt;set-property property="password" value="the password used to create connections"/&gt; <BR>&lt;set-property property="user" value="the username used to create connections"/&gt; <BR>&lt;/data-source&gt; <BR>&lt;/data-sources&gt; <BR>&lt;data-source&gt;的属性及其描述信息如下： <BR>属&nbsp; 性&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 描 述 信 息 <BR>Key&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 绑定在ServletContext上的DataSource实例的索引键， <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 若不设定则缺省为Action.DATA_SOURCE_KEY，如果在应用程序中有多于一个的DataSource， <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 则必须设置Key的值。 <BR>DriverClass&nbsp;&nbsp;&nbsp; 所用的JDBC驱动类(必须的)如：com.microsoft.jdbc.sqlserver.SQLServerDriver <BR>url&nbsp;&nbsp;&nbsp; 所用的JDBC的URL(必须的)如：jdbc:microsoft:sqlserver://xg088:1433 <BR>MaxCount&nbsp;&nbsp;&nbsp; 同时打开的最大连结数，缺省值为2(可选的) <BR>MinCount&nbsp;&nbsp;&nbsp; 同时打开的最小连结数，缺省值为1(可选的) <BR>User&nbsp;&nbsp;&nbsp; 连结到数据库的用户名(必须的) <BR>Password&nbsp;&nbsp;&nbsp; 连结到数据库的密码(必须的) <BR>Description&nbsp;&nbsp;&nbsp; 关于DataSource的描述信息(可选的) <BR>ReadOnly&nbsp;&nbsp;&nbsp; 如果设为true，则表示该连结是只读的，缺省为false。(可选的) <BR>LoginTimeout&nbsp;&nbsp;&nbsp; 创建连结的最大允许时间，以秒为单位。(可选的) <BR>AutoCommit&nbsp;&nbsp;&nbsp; 如果为true，则每次execute之后会强制回滚。缺省为true。(可选的) <BR>举例说明： <BR>&lt;data-sources&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;data-source&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;set-property property=”key” value=” value="WILEY_DATA_SOURCE" /&gt; <BR>&lt;set-property property="driverClass" value="org.gjt.mm.mysql.Driver" /&gt; <BR>&lt;set-property property="url" value="jdbc:mysql://localhost/wileyusers" /&gt; <BR>&lt;set-property property="maxCount" value="5"/&gt; <BR>&lt;set-property property="minCount" value="1"/&gt; <BR>&lt;set-property property="user" value="sa"/&gt; <BR>&lt;set-property property="password" value="yourpassword"/&gt; <BR>&lt;/data-source&gt; <BR>&lt;/data-sources&gt; </P>
<P>四、&nbsp;&nbsp;&nbsp; 配置FormBean <BR>&lt;form-bean / &gt;用来定义将要绑定到Action的FormBean的实例。语法如下： <BR>&nbsp;&lt;form-beans&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;form-bean name="name used to uniquely identify a FormBean" <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; type=”fully qualified class name of FormBean"/&gt; <BR>&nbsp;&lt;/form-beans&gt; <BR>例： <BR>&lt;form-beans&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;form-bean name="lookupForm" type="wiley.LookupForm" /&gt; <BR>&lt;/form-beans&gt; </P>
<P>五、&nbsp;&nbsp;&nbsp; 配置全局转发 <BR>&nbsp;&nbsp; 全局转发可以定义几个&lt;forward/&gt;子元素，struts首先会在&lt;action-mappings&gt;元素中找对应的&lt;forward&gt;， </P>
<P>若找不到，则到全局转发配置中找。语法如下： <BR>&lt;global-forwards&gt; <BR>&nbsp; &lt;forward name="unique target identifier" path="context-relative path to targetted resource "/&gt; <BR>&lt;/global-forwards&gt; <BR>&nbsp;&nbsp; 除了name及path属性之外，还有一个redirect属性，如果redirect设为true的时候，则用 </P>
<P>HttpServletResponse.sendRedirect()方法，否则用RequestDispatcher.forward()方法，缺省为false。 <BR>注：如果为true，则用HttpServletResponse.sendRedirect()方法，此时存储在原来的HttpServletRequest中 </P>
<P>的值将会丢失。 <BR>例子： <BR>&lt;global-forwards&gt; <BR>&lt;forward name="success" path="/welcome.jsp"/&gt; <BR>&lt;forward name="failure" path="/index.jsp"/&gt; <BR>&lt;/global-forwards&gt; <BR>六、&nbsp;&nbsp;&nbsp; 配置&lt;action-mappings&gt; <BR>&nbsp;&nbsp; 它可以定义几个&lt;action / &gt;子元素，它主要是定义Action实例到ActionServlet类中，语法如下： <BR>&lt;action-mappings&gt; <BR>&nbsp;&lt;action path="context-relative path mapping action to a request" <BR>&nbsp;&nbsp; type="fully qualified class name of the Action class" <BR>&nbsp;&nbsp; name="the name of the form bean bound to this Action"&gt; <BR>&nbsp;&nbsp; &lt;forward name="forwardname1" path="context-relative path"/&gt; <BR>&nbsp;&nbsp; &lt;forward name="forwardname2" path="context-relative path"/&gt; <BR>&nbsp;&lt;/action&gt; <BR>&lt;/action-mappings&gt; <BR>&lt;action/&gt;属性及其描述信息如下： <BR>属&nbsp; 性&nbsp;&nbsp;&nbsp; 描 述 信 息 <BR>Path&nbsp;&nbsp;&nbsp; 在浏览器的URL中输入的字符(必须的) <BR>Type&nbsp;&nbsp;&nbsp; 连结到本映射的Action的全称(可选的) <BR>Name&nbsp;&nbsp;&nbsp; 与本操作关联的Action Bean在&lt;form-bean/&gt;中定义name名(可选的) <BR>Scope&nbsp;&nbsp;&nbsp; 指定ActionForm Bean的作用域(session和request)，缺省为session。(可选的) <BR>Input&nbsp;&nbsp;&nbsp; 当Bean发生t误时返回的控制。(可选的) <BR>ClassName&nbsp;&nbsp;&nbsp; 指定一个调用这个Action类的ActionMapping类的全名。缺省用 </P>
<P>org.apache.struts.action.ActionMapping，(可选的) <BR>Forward&nbsp;&nbsp;&nbsp; 指定处理相应请求所对应的JSP页面。(可选的) <BR>Include&nbsp;&nbsp;&nbsp; 如果没有forward的时候，它起forward的作用。(可选的) <BR>Validate&nbsp;&nbsp;&nbsp; 若为true，则会调用ActionForm的validate()方法，否则不调用，缺省为true。（可选的） <BR>例子： <BR>&lt;action-mappings&gt; <BR>&lt;action path="/lookupAction" type="wiley.LookupAction" name="LookupForm" <BR>&nbsp; scope="request" <BR>&nbsp; validate="true" <BR>&nbsp; input="/index.jsp"&gt; <BR>&lt;forward name="success" path="/quote.jsp"/&gt; <BR>&lt;forward name="faliue" path="/index.jsp"/&gt; <BR>&lt;/action&gt; <BR>&lt;/action-mappings&gt; </P>
<P>七、&nbsp;&nbsp;&nbsp; 配置RequestProcessor <BR>&nbsp;&nbsp;&nbsp; 在struts-config.xml文件中用&lt;controller/&gt;子元素来定义RequestProcessor，其语法格式如下： <BR>&lt;controller processorClass="fully qualified class name" /&gt; <BR>&lt;controller /&gt;元素属性及其描述信息如下： <BR>属&nbsp; 性&nbsp;&nbsp;&nbsp; 描&nbsp; 述 <BR>processorClass&nbsp;&nbsp;&nbsp; 指定自定义的RequestProcessor类的全名 <BR>BufferSize&nbsp;&nbsp;&nbsp; 指定用来下载所用的缓存大小。缺省是4096字节。 <BR>contentType&nbsp;&nbsp;&nbsp; 定义response文本类型，缺省是text/html <BR>Debug&nbsp;&nbsp;&nbsp; 定义当前系统的除错级别，缺省是0 <BR>Locale&nbsp;&nbsp;&nbsp; 如果是true，则在用户的session中存放Locale对象，缺省为true <BR>maxFileSize&nbsp;&nbsp;&nbsp; 指定下载文件最大的大小。缺省是250M <BR>multipartClass&nbsp;&nbsp;&nbsp; 指定去代替org.apache.struts.upload.DiskMultipartRequestHandler类的类的全名。 <BR>Nocache&nbsp;&nbsp;&nbsp; 如果是true，则会关闭每个response的缓存功能。缺省是false <BR>TempDir&nbsp;&nbsp;&nbsp; 指定上载文件所用的临时目录。缺省值由容器决定 <BR>例子： <BR>① &lt;controller processorClass="wiley.WileyRequestProcessor" /&gt; <BR>② &lt;controller <BR>&nbsp;&nbsp;&nbsp; contentType="text/html;charset=UTF-8" <BR>&nbsp;&nbsp;&nbsp; debug="3" <BR>&nbsp;&nbsp;&nbsp; locale="true" <BR>&nbsp;&nbsp;&nbsp; nocache="true" <BR>&nbsp;&nbsp;&nbsp; processorClass="org.apache.struts.action.RequestProcessor"/&gt; </P>
<P>八、&nbsp;&nbsp;&nbsp; 配置Message Resources <BR>&nbsp;&nbsp;&nbsp; 在struts-config.xml文件中用&lt;message-resources /&gt;元素来定义消息资源。其语法如下： <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;message-resources&nbsp; parameter="wiley.ApplicationResources"/&gt; <BR>&lt;message-resources /&gt;元素属性及其描述信息如下： <BR>属&nbsp; 性&nbsp;&nbsp;&nbsp; 描&nbsp; 述 <BR>Parameter&nbsp;&nbsp;&nbsp; 给定资源文件全名 <BR>ClassName&nbsp;&nbsp;&nbsp; 定义处理消息资源的类名的全名，缺省是org.apache.struts.config.MessageResourcesConfig <BR>Factory&nbsp;&nbsp;&nbsp; 定义MessageResourcesFactory类的全名，缺省是 </P>
<P>org.apache.struts.util.property.MessageResourcesFacotry <BR>Key&nbsp;&nbsp;&nbsp; 定义绑定在这个资源包中的ServletContext的属性主键，缺省值是Action.MESSAGES_KEY. <BR>Null&nbsp;&nbsp;&nbsp; 如果为true，则找不到消息key时，则返回null，缺省是true. <BR>例子： <BR>① &lt;message-resources parameter="wiley.ApplicationResources"/&gt; <BR>② &lt;message-resources <BR>&nbsp;&nbsp;&nbsp; parameter="StorefrontMessageResources" <BR>&nbsp;&nbsp;&nbsp; null="false"/&gt; <BR>&lt;message-resources <BR>&nbsp;&nbsp;&nbsp; key="IMAGE_RESOURCE_KEY" <BR>&nbsp;&nbsp;&nbsp; parameter="StorefrontImageResources" <BR>&nbsp;&nbsp;&nbsp; null="false"/&gt; <BR>注意：设定key的目的如下： <BR>&lt;html:img altKey="navbar.home.image.alt" bundle="IMAGE_RESOURCE_KEY"&nbsp; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pageKey="navbar.home.image" width="125" height="15" border="0"/&gt; <BR>这里说明要到StorefrontImageResources.properties资源文件中找主键值是”navbar.home.image”所对应的 </P>
<P>值。 <BR>这里StorefrontImageResources.properties的内容如下： <BR>…… <BR>navbar.home.image=/images/home.gif <BR>navbar.home.image.alt=Home <BR>…… <BR>此处navbar.home.image.alt说明的和&lt;img alt=”Home”……/&gt;一样。 </P>
<P>九、&nbsp;&nbsp;&nbsp; 配置Plug-in <BR>配置Plug-in如下： <BR>&lt;plug-in className="wiley.WileyPlugin"/&gt; <BR>也可如下： <BR>&lt;plug-in className="com.oreilly.struts.storefront.service.memory.StorefrontMemoryDatabasePlugIn"&gt; <BR>&nbsp; &lt;set-property property="pathname" value="/WEB-INF/database.xml"/&gt; <BR>&lt;/plug-in&gt; </P>
<P>&nbsp;<BR></P>]]></description>
<pubDate>
2007-05-16 23:56:03.0</pubDate>
<guid>
http://ljbedu.blogcn.com/diary,4430911.shtml</guid>
<comments>
http://ljbedu.blogcn.com/diary,4430911.shtml#comment</comments>
</item>
<item>
<blogcn_uid>
<![CDATA[9090865]]></blogcn_uid>
<title>
<![CDATA[实用Struts应用程序编写实例]]></title>
<link>
http://ljbedu.blogcn.com/diary,4104347.shtml</link>
<description>
<![CDATA[<P class=MsoNormal style="MARGIN: 0cm 0cm 12pt; LINE-HEIGHT: 16.5pt"><FONT face="Times New Roman"><FONT color=#000000><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt">Struts</SPAN></B></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"> </SPAN></SPAN></FONT></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts </FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">框架完全是用</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Java </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">写的，写时用了标准</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> J2EE API</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。另外，它还采用了几种著名的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> J2EE </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">设计模式，比如模型</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">-</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">视图</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">-</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">控制器（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Model-view-controller</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> FrontController</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">模型</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">-</FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">视图</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">-</FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">控制器（</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">MVC</FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">模型</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">-</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">视图</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">-</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">控制器（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">MVC</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）是一种设计模式，它在定义下面三个应用层时作了明确的区分。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·模型（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">model</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）是应用程序的数据和业务规则集合。通常被称作应用程序的业务逻辑。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·视图（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">view</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）是应用程序的用户界面。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·控制器（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">controller</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）定义了应用程序与用户输入及模型进行交互的方式。它被称作应用程序逻辑。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">通过明确区分各个层，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">MVC </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">允许组成每个层的各个组件间松散地耦合。这使它更加灵活，并且可以重用代码。例如，如果您为一个应用程序开发了几个用户界面，那么就需要开发视图组件，因为各应用层间是松散耦合的。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">框架是</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> MVC </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的视图和控制器组件。下面展示了</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">怎样映射为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> MVC </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">框架。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">有三个主要组成部分：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Action bean </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionServlet </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionForm bean </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和定制的标记。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> <BR></FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><SPAN class=myp1111><B><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">Action bean </FONT></SPAN></B></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionServlet</FONT></SPAN></B></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">提供了一个单独的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionServlet</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">org.apache.struts.action.ActionServlet</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）来处理所有的浏览器请求。这种类型的框架我们称之为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> FrontController </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">模式。每个浏览器请求都由</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">org.apache.struts.action.Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的子类）来处理。每个浏览器请求都被映射为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> struts-config.xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">文件内的一个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionServlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">在初始化期间加载这种映射。要配置</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Web </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">项目使其把所有的浏览器请求都传递给</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionServlet</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，请把所有以</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> .do </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">结尾的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> URI</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">（例如</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> *.do</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）都映射为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Web </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">部署描述符中的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionServlet</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。然后您可以在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">配置文件中为各个请求</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> URI</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">（比如</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> /submit.do</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）提供实际的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类映射。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><FONT face="Times New Roman"><SPAN class=myp1111><B><SPAN style="LETTER-SPACING: 0pt">ActionForm bean</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"> </SPAN></SPAN></FONT></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">浏览器请求可带参数。当用户提交</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> HTML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">表单后，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">框架就把参数放在一个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> org.apache.struts.action.ActionForm bean </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">中。您也可以用</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionForm bean </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">把缺省值预先植入一个表单，这些缺省值可从数据库或其他的后端系统获得。如果用户在表单中输入了不正确的值，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">可以进行验证。您可以用以前的输入重新显示表单。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">定制的标记</SPAN></B></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">提供了许多支持</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionForm bean </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> JSP </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">定制标记。这些定制的标记支持：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·把从</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类中获得的值预先植入</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> HTML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">表单。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·国际化，比如提供由用户语言环境决定的文本。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·逻辑，比如根据人们对页面的使用方式为其显示不同的标题。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts </FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">是一个通用的框架，您可以很容易地把它和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> WebSphere Studio </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">一起使用。下面我们来开始第一个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">示例。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">编写一个简单的</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">应用程序</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">先决条件：启动</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> WebSphere Studio </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">版本</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> 5.0</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·转到</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Window Start </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">菜单。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·选择</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> <B><SPAN lang=EN-US>Programs =&gt; IBM WebSphere Studio =&gt; Application Developer 5.0</SPAN></B></FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">第</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> 1 </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">步：开始一个新的</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts Web </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">项目</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts Setting </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面中选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Override default settings</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，并在下拉框中选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> 1.1 (beta 2) </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，如图</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">2 </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">所示。前面已经提到过，表单被提交时，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">HTML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">表单数据被自动植入</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts ActionForm</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts 1.0.1 </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">只支持简单的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Java </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类型。而</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts 1.1</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">beta 2</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）还支持</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> java.util.HashMap </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">或其他的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Collection </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类型。这一点我们将在本文的后面部分讨论。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">单击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Finish</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> <BR></FONT></SPAN></SPAN></FONT><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">您将稍后修改下面的文件：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ApplicationResources.properties </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">是</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">应用程序的资源绑定。语言环境的详细信息和错误消息都放在这个属性文件中。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">struts-config.xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">是</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">配置文件。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">WebSphere Studio </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">为这个文件提供了一个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> GUI </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">编辑器。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">现在，请执行下列操作：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">1.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">检查</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> web.xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">文件。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">2.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">展开</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> StrutsSampleWeb </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">项目并双击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Web Deployment Descriptor </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">来打开编辑器。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">转到</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Servlets </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面。请注意下面两点：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·名为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts org.apache.struts.action.ActionServlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的定义。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">·到这个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> servlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> URL </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">映射，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">*.do</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">请注意，在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Initialization </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">部分，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">validate </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">被设为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> true</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionServlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">用</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> XML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">解析器来验证和处理配置文件。它与表单验证无关，稍后在本文中您将看到这一点。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><B><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">*.do </FONT></SPAN></B></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">怎样获得正确的</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Action </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类？</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">前面已经提到过，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionServlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类是</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> MVC </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">模型中控制器层的核心。该控制器负责处理用户的请求，把请求路由到业务逻辑，并选择视图来响应用户（请参阅</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">用户指南，第</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> 4.4 </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">节）。表单提交给</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> submit.do </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">后，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts ActionServlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">会根据</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> struts-config.xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">文件中的</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">选择正确的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类来用。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts Action </FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类负责处理用户数据。在这个示例中，创建一个名为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> SubmitAction </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类。它由诸如读和处理表单数据之类的操作组成。每一个表单都和该</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类的一个实例关联在一起。请创建这个继承</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的表单类。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">SubmitForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">是</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的一个子类，它是用域的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> getter </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> setter </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">方法创建的。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">getter </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> setter </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">方法在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">子类中都是必须有的。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><B><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">SubmitForm </FONT></SPAN></B></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">怎样发挥作用？</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">每一个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类都必须和一个</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类关联在一起。您可以在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> WebSphere Studio </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">中的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> struts-config.xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">编辑器的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> FormBean </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面中定义</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> SubmitForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类。然后可以把它与</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> struts-config.xml </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">文件中的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> SubmitAction </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">映射关联在一起。一个请求提交后，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionServlet </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">把从</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Web </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">浏览器上的实际表单中得到的数据自动植入</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> SubmitForm</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> SubmitAction </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类中，用</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> SubmitForm f = (SubmitForm) form </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">来访问表单数据。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">第</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> 2 </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">步：用</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts taglib </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">构建一个</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> JSP </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">表单</SPAN></B></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">为输入域提供了许多</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> HTML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">标记并为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> JSP </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">表单提供了许多超链接。下面列出了常用的几个：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR style="mso-special-character: line-break"><BR style="mso-special-character: line-break"><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p></SPAN></SPAN></SPAN></P>
<DIV align=center>
<TABLE style="WIDTH: 300pt; mso-padding-alt: 1.5pt 1.5pt 1.5pt 1.5pt; mso-cellspacing: 0cm" cellSpacing=0 cellPadding=0 width=500 border=1>
<TBODY>
<TR>
<TD style="BORDER-RIGHT: #ece9d8; PADDING-RIGHT: 1.5pt; BORDER-TOP: #ece9d8; PADDING-LEFT: 1.5pt; BACKGROUND: #e6e6e6; PADDING-BOTTOM: 1.5pt; BORDER-LEFT: #ece9d8; PADDING-TOP: 1.5pt; BORDER-BOTTOM: #ece9d8"><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·复选框<SPAN lang=EN-US> - &lt;html:checkbox property="name"/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·隐藏域<SPAN lang=EN-US> - &lt;html:hidden property="name"/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·密码输入域<SPAN lang=EN-US> - &lt;html:password property="name"/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·单选按钮<SPAN lang=EN-US> - &lt;html:radio property="name"/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·重设按钮<SPAN lang=EN-US> - &lt;html:reset/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·选项（下拉框）<SPAN lang=EN-US> &lt;html:select property="name"/&gt;</SPAN></FONT></FONT></FONT></PRE><PRE><SPAN lang=EN-US><FONT face=黑体 color=#000000 size=2>&lt;html:option value="a"/&gt;choice1&lt;/html:option&gt;</FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT face=黑体 color=#000000 size=2>&lt;/html:select&gt;</FONT></SPAN></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·提交按钮<SPAN lang=EN-US> - &lt;html:submit/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·文本输入域<SPAN lang=EN-US> - &lt;html:text property="name"/&gt; </SPAN></FONT></FONT></FONT></PRE><PRE><FONT size=2><FONT color=#000000><FONT face=黑体>·文本区输入域<SPAN lang=EN-US> - &lt;html:textarea property="name"/&gt;</SPAN></FONT></FONT></FONT></PRE></TD></TR></TBODY></TABLE></DIV>
<P class=MsoNormal style="MARGIN: 0cm 0cm 12pt; LINE-HEIGHT: 16.5pt"><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">大多数</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> HTML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">标记都支持</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Javascript </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">事件，如</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> onmouseclick</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">、</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">onmouseover </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">等事件。关于更多信息，请参阅</SPAN></SPAN></FONT><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"><FONT color=#000000> </FONT><SPAN lang=EN-US><A href="http://jakarta.apache.org/struts/userGuide/struts-html.html">HTML Bean API</A></SPAN></FONT></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。下面我们来为这个示例创建一张</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> JSP </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面。在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Web Perspective </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">中，用</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">模型创建一张</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> JSP </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">1.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">展开</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> StrutsSampleWeb </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">项目直到看到</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> /Web Content </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">文件夹。右键单击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> /Web Content</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">2.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> New =&gt; JSP File</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">3.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Name </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">中输入</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> submitpage.jsp</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">4.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">从下拉框中选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts JSP </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">作为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Model</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">5.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">单击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Next</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，注意只添加了</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> HTML </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Bean </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> <SPAN lang=EN-US>taglib</SPAN></FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。如果您想使用其他标记库中的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> taglib</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，如</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Logic taglib</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，请选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Add Tag Libraries</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">，然后选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> /WEB-INF/struts-logic.tld</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">6.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">单击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Finish</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> <BR></FONT></SPAN></SPAN></FONT><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">用源代码编辑器中的下面这些代码修改</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> submitpage.jsp </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页并保存：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR style="mso-special-character: line-break"><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><o:p></o:p></SPAN></SPAN></SPAN></P>
<DIV align=center>
<TABLE style="WIDTH: 300pt; mso-padding-alt: 1.5pt 1.5pt 1.5pt 1.5pt; mso-cellspacing: 0cm" cellSpacing=0 cellPadding=0 width=500 border=1>
<TBODY>
<TR>
<TD style="BORDER-RIGHT: #ece9d8; PADDING-RIGHT: 1.5pt; BORDER-TOP: #ece9d8; PADDING-LEFT: 1.5pt; BACKGROUND: #e6e6e6; PADDING-BOTTOM: 1.5pt; BORDER-LEFT: #ece9d8; PADDING-TOP: 1.5pt; BORDER-BOTTOM: #ece9d8"><PRE><SPAN lang=EN-US><FONT face=黑体 color=#000000 size=2>&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"&gt;</FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 1"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:html locale="true"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 1"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;HEAD&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;%@ page</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>language="java"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>contentType="text/html; charset=ISO-8859-1"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>pageEncoding="ISO-8859-1"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>%&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;META name="GENERATOR" content="IBM WebSphere Studio"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;META http-equiv="Content-Style-Type" content="text/css"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;LINK href="theme/Master.css" rel="stylesheet"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 2">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>type="text/css"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 2"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 2"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;TITLE&gt;Pizza Order Page&lt;/TITLE&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/HEAD&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 1"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;BODY&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 2">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;P&gt;&lt;h1&gt;Pizza Order Page &lt;/h1&gt;&lt;/P&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 2"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:form action="/submit.do"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 2"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Name: &lt;html:text property="customer.name"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Address: &lt;html:text property="customer.address"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 3"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Size: &lt;html:radio property ="size" value="S"/&gt;Small</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:radio property ="size" value="M"/&gt;Medium</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:radio property ="size" value="L"/&gt;Large</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 3"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Toppings: &lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Pepperoni&lt;html:checkbox property="topping(Pepperoni)"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Onion&lt;html:checkbox property="topping(Onion)"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Mushroom&lt;html:checkbox property="topping(Mushroom)"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Hot Pepper&lt;html:checkbox property="topping(Hot Pepper)"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>Bacon&lt;html:checkbox property="topping(Bacon)"/&gt;&lt;br&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 3"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:select property ="type"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:option value="a"&gt;Delivery&lt;/html:option&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:option value="b"&gt;Pickup&lt;/html:option&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/html:select&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 3"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 4">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:submit/&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 4">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:reset/&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 3">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/html:form&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/BODY&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/html:html&gt;</FONT></FONT></FONT></SPAN></PRE></TD></TR></TBODY></TABLE></DIV>
<P class=MsoNormal style="MARGIN: 0cm 0cm 0pt; LINE-HEIGHT: 16.5pt"><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">忽略任务列表中关于</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> submit.do </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">不存在的警告消息。为</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts Action </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类创建一张</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> /confirm.jsp </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面用来进行转发。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Web Perspective </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">中，创建</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> confirm.jsp </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">页面：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">1.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">右键单击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> /Web Content</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">2.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">选择</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> New =&gt; JSP File</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">3.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Name </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">域中输入</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> confirm.jsp</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><FONT face="Times New Roman">4.</FONT></SPAN></SPAN></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">单击</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Finish</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">用下面的代码修改</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> JSP </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">文件：</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR style="mso-special-character: line-break"><SPAN class=myp1111><SPAN style="LETTER-SPACING: 0pt"><o:p></o:p></SPAN></SPAN></SPAN></P>
<DIV align=center>
<TABLE style="WIDTH: 300pt; mso-padding-alt: 1.5pt 1.5pt 1.5pt 1.5pt; mso-cellspacing: 0cm" cellSpacing=0 cellPadding=0 width=500 border=1>
<TBODY>
<TR>
<TD style="BORDER-RIGHT: #ece9d8; PADDING-RIGHT: 1.5pt; BORDER-TOP: #ece9d8; PADDING-LEFT: 1.5pt; BACKGROUND: #e6e6e6; PADDING-BOTTOM: 1.5pt; BORDER-LEFT: #ece9d8; PADDING-TOP: 1.5pt; BORDER-BOTTOM: #ece9d8"><PRE><SPAN lang=EN-US><FONT face=黑体 color=#000000 size=2>&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"&gt;</FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;html:html&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;HEAD&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;%@ page </FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>language="java"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>contentType="text/html; charset=ISO-8859-1"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>pageEncoding="ISO-8859-1"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>%&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;META name="GENERATOR" content="IBM WebSphere Studio"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;META http-equiv="Content-Style-Type" content="text/css"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;LINK href="theme/Master.css" rel="stylesheet"</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 2">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>type="text/css"&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;TITLE&gt;&lt;/TITLE&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/HEAD&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><SPAN style="mso-tab-count: 1"><FONT face=黑体 color=#000000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></SPAN></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;BODY&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;P&gt;Thank you &lt;%=request.getAttribute("name")%&gt;&lt;/P&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/BODY&gt;</FONT></FONT></FONT></SPAN></PRE><PRE><SPAN lang=EN-US><FONT size=2><FONT color=#000000><FONT face=黑体><SPAN style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </SPAN>&lt;/html:html&gt;</FONT></FONT></FONT></SPAN></PRE></TD></TR></TBODY></TABLE></DIV>
<P class=MsoNormal style="MARGIN: 0cm 0cm 0pt"><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">在</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> submitpage.jsp </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">中，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">customer.name </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">属性引用对象内的一个域。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">topping(Pepperoni) </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">属性是</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> java.util.HashMap </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">的一个键／值对。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">Struts 1.1</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">（</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">beta 2</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">）</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">HTML taglib </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">支持嵌套的属性。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><o:p></o:p></SPAN></SPAN></FONT></P>
<P class=MsoNormal style="MARGIN: 0cm 0cm 12pt; LINE-HEIGHT: 16.5pt"><FONT color=#000000><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">第</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> 3 </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">步：创建一个</SPAN></B></SPAN><SPAN class=myp1111><B><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts ActionForm SubmitForm </FONT></SPAN></B></SPAN><SPAN class=myp1111><B><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类</SPAN></B></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> </FONT></SPAN></SPAN></FONT><SPAN lang=EN-US style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: ''"><BR><BR></SPAN><FONT color=#000000><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">您必须定义一个继承</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> Struts ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类的子类。它必须有用于所有表单域的</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> setter </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">和</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman"> getter</FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">。前面已经提到过，提交表单后，</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类被预先植入表单数据。</SPAN></SPAN><SPAN class=myp1111><SPAN lang=EN-US style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT face="Times New Roman">ActionForm </FONT></SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 宋体; LETTER-SPACING: 0pt; mso-hansi-font-family: ''; mso-ascii-font-family: ''">类有验证方法和重设方法（可选）分别用来验证表单输入和重新设置表单。稍后将在本文中讨论它们。</SPAN></SPAN><SPAN class=myp1111><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: ''; LETTER-SPACING: 0pt"><FONT 