The exact same thing happens. I give you some more information. You know how my
web.xml looks like. Here are the other files:
struts.xml:
------------
<!DOCTYPE struts PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
"http://struts.apache.org/dtds/struts-2.0.dtd">
<struts>
<include file="struts-default.xml"/>
<package name="default" extends="struts-default">
<action name="helloWorld" class="HelloWorld">
<result name="success">helloWorld.jsp</result>
</action>
</package>
</struts>
helloWorld.jsp:
---------------
<%@ taglib prefix="saf" uri="/tags" %>
<html>
<head>
<title>Hello World</title>
</head>
<body>
The message generated by my first Action is:
<saf:property value="message"/>
</body>
</html>
HelloWorld.java:
----------------
import com.opensymphony.xwork2.Action;
import java.util.*;
import java.text.DateFormat;
public class HelloWorld implements Action {
private String message;
public String execute() {
message = "Hello, World!\n";
message += "The time is:\n";
message += DateFormat.getDateInstance().format(new Date());
return SUCCESS;
}
public String getMessage() {
return message;
}
}
Thanks,
Peter
-------- Original-Nachricht --------
Datum: Thu, 17 Aug 2006 14:04:52 -0500
Von: [EMAIL PROTECTED]
An: [email protected]
Betreff: RE: Struts2
> It looks like you're requesting a page with suffix mapping
> ("helloWorld.do") but you've configured struts to use prefix mapping ("/*").
> What happens
> if you change to "<url-pattern>*.do</url-pattern>"?
>
> - George
> http://www.idiacomputing.com/
>
>
> > -----Original Message-----
> > From: Peter Steil [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, August 17, 2006 2:01 PM
> > To: [email protected]
> > Subject: Struts2
> >
> >
> > Hi, I am trying to get started on Struts2 using the nightly
> > build 'struts2-core-2.0.0-SNAPSHOT-20060816.jar'. I started
> > with the very basic example from
> > 'http://cwiki.apache.org/WW/hello-world.html' and I still get
> > the message 'The requested resource (/mystruts/helloWorld.do)
> > is not available.' in my browser. My web.xml looks like this:
> >
> > <?xml version="1.0"?>
> > <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
> > Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
> >
> > <web-app>
> > <display-name>My Application</display-name>
> > <filter>
> > <filter-name>action2</filter-name>
> >
> > <filter-class>org.apache.struts2.dispatcher.FilterDispatcher</
> filter-class>
> > </filter>
> >
> > <filter-mapping>
> > <filter-name>action2</filter-name>
> > <url-pattern>/*</url-pattern>
> > </filter-mapping>
> > <listener>
> >
> > <listener-class>org.springframework.web.context.ContextLoaderL
> > istener</listener-class>
> > </listener>
> > </web-app>
> >
> >
> > Can anybody help me?
> > Thanks,
> > Peter
> > --
> >
> >
> > Echte DSL-Flatrate dauerhaft für 0,- Euro*. Nur noch kurze
> > Zeit! "Feel free" mit GMX DSL: http://www.gmx.net/de/go/dsl
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
--
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]