![]() |
|
||||||||||||||
| | 网站首页 | 数据库教程 | web编程 | 服务器 | 程序设计 | | ||
|
||
|
||||||
| 在Struts2中怎样用Groovy语言来写Action | ||||||
作者:佚名 文章来源:不详 点击数: 更新时间:2007-9-2 ![]() |
||||||
|
我们在作Struts2的项目时,如果我们更新了Java程序(这里主要是指Action)我们需要重新启动Tomcat或者Web Context。
这里我使用Struts2+Spring+Groovy1.0来做一个列子。
注意其中对schema的引用。
![]() <action name="groovyHelloWorld" class="groovyHelloWorldAction"> <result>/helloworld.jsp</result> </action>
<%@ taglib divfix="s" uri="/struts-tags" %> <html> <head> <title>Groovy Hello World!</title> </head> <body> <h2><s:property value="message" /></h2> </body> </html>
启动Tomcat,在访问http://localhost:8080/myapp/groovyHelloWorld.action 本文来源:http://blog.csdn.net/kongxx/archive/2007/07/23/1704220.aspx
|
||||||
| 文章录入:admin 责任编辑:admin | ||||||
| 【发表评论】【加入收藏】【告诉好友】【打印此文】【关闭窗口】 | ||||||
| 网友评论:(只显示最新10条。评论内容只代表网友观点,与本站立场无关!) |
| | 设为首页 | 加入收藏 | 联系站长 | 友情链接 | 版权申明 | 网站公告 | 网站地图 | 管理登录 | | |||
|