带有 Eclipse 的 struts 2 简单 helloworld 示例 [英] struts 2 simple helloworld example with eclipse

查看:34
本文介绍了带有 Eclipse 的 struts 2 简单 helloworld 示例的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在网上尝试了很多例子.但是我仍然无法使用 struts 2 运行一个简单的 helloworld 程序.每当我尝试时,如果我按照网络中的示例正确执行了步骤,我就会收到找不到资源的错误".如果有人可以粗暴地给我一步一步的程序,那将对我有很大帮助!

I tried lot of exmaples in net. But still i'm unable to run a simple helloworld program using struts 2 . Whenever i'm trying i'm getting the "resource not found error" evn though if i followed the steps correctly as per the example in the net. If any one can give me a step by step procedure surly it will a great help for me!

推荐答案

我已经针对这个问题多次发帖,开始学习任何框架的最佳方法是尝试动手解决与框架一起不信任的示例应用程序.

I have posted several times for this problem, best way to start learning any framework is to try there hands around the example applications being distrusted along with the framework.

Struts2 在这方面也不例外.只需从官方下载页面下载示例应用程序并在您的 tomcat 中运行

Struts2 is not an exception in this.Just download sample applications from there official download page and run in your tomcat

它不仅会为您提供一个运行示例,还会帮助您了解他们如何打包应用程序,哪些资源在哪些地方使用,需要哪些依赖项以及运行应用程序需要哪些其他配置

It will not only give you a running example but also will help you to understand how they have packed there application what resources is going at what places,what are the required dependencies and what other configurations one need to run an application

Struts2 示例应用程序下载

从这里下载示例应用程序,您将获得 struts2-blank-x.x.x war 文件,它是一个标准的 struts2 结构,可以运行 hello world 应用程序

Download sample applications from here and you will get struts2-blank-x.x.x war file which is a standard struts2 structure with running hello world application

关于 maven,它是创建标准应用程序结构的最佳方法,但如果您不熟悉 maven,那么我最好的建议是现在花时间学习 Struts2,并且可以在此过程中捕获 maven

Regarding maven its a best way to create a standard application structure to start with but if you are not familiar with maven than my best suggestion is to put time to learn Struts2 at the moment and maven can be captured along the way

这篇关于带有 Eclipse 的 struts 2 简单 helloworld 示例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆