Servlet action is currently unavailable

Hi,

I got "Servlet action is currently unavailable" Error.

For reference I'm placing web.xml & structs-config.xml.

Please tell me why this error is occuring.

Web.xml

<?xml version="1.0" encoding="UTF-8"?>

<!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>

<servlet>

<servlet-name>action</servlet-name>

<servlet-class>

org.apache.struts.action.ActionServlet

</servlet-class>

<init-param>

<param-name>config</param-name>

<param-value>/WEB-INF/struts-config.xml</param-value>

</init-param>

<load-on-startup>1</load-on-startup>

</servlet>

<servlet-mapping>

<servlet-name>action</servlet-name>

<url-pattern>*.do</url-pattern>

</servlet-mapping>

</web-app>

struts-config.xml

-

<?xml version="1.0" encoding="iso-8859-1"?>

<!DOCTYPE struts-config SYSTEM

"http://jakarta.apache.org/struts/dtds/struts-config_1_2.dtd">

<struts-config>

<action-mappings>

<action path="/displayAddProductForm"

forward="/displayAddProductForm.jsp"/>

<action path="/saveProduct" scope="request"

type="tutorial.SaveProductAction">

<forward name="success" path="/displaySavedProduct.jsp"/>

</action>

</action-mappings>

</struts-config>

[2001 byte] By [vrihari_Que_Ansa] at [2007-10-2 20:28:22]
# 1
works for me.Do you have struts.jar (and other supporting jars) in the WEB-INF/lib directoryWhat server/version are you using?
evnafetsa at 2007-7-13 23:11:18 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
Hi, I Included servlet.jar in WEB-INF/lib. I'm using Tomcat4.1. I don't know where I'm doing mistake. Please clear me.Thanks,Hari.
vrihari_Que_Ansa at 2007-7-13 23:11:18 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

Hi,

I rewrite the action-mapping part of struts-config.xml file as

<action-mappings>

<action path="/displayAddProductForm"type="tutorial.UserRegistrationAction">

<forward name="success" path="/displayAddProdutForm.jsp"/>

</action>

</action-mappings>

Here only if I write the action part("type" attribute), its working, previously without action part it didnt work. Why tell me what will be the reason.?

Thanks,

Hari

vrihari_Que_Ansa at 2007-7-13 23:11:18 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...