Lukasz Lenart escribió:
Hi,
Could you paste your struts-config here?
Regards
Hi,
This is the whole struts-config file. As fas as i can see, the problem
has nothing to do with the actionClass itself, because I only put a
simple forward in the action, and the result is the same as with the
code i must program. The browser gets stucked in the action *.do, as if
it would enter in a loop.No errors are shown in the Tomcat console nor
the logs. In the navigator bar and the window title (where the name of
the actual jsp page is displayed) appears the same name as in the nav
bar: http://localhost:8080/gentaiw/mostrarusuario.do , (mostrarusuario
means showuser) instead of mostrarUsuario.jsp
More info , the global forward "<forward name="irMostrarTest"
path="/mostrarConfigurarTest.do" />" works fine.
Best regards,
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD
Struts Configuration 1.2//EN"
"http://struts.apache.org/dtds/struts-config_1_2.dtd">
<struts-config>
<data-sources>
<data-source type="org.apache.commons.dbcp.BasicDataSource"
key="usuario" >
<set-property property="driverClassName"
value="com.mysql.jdbc.Driver" />
<set-property property="url"
value="jdbc:mysql://localhost:3306/gentaidb?autoReconnect=true" />
<set-property property="username" value="root" />
<set-property property="password" value="admin" />
<set-property property="maxActive" value="10" />
<set-property property="maxWait" value="5000" />
<set-property property="defaultAutoCommit" value="false" />
<set-property property="defaultReadOnly" value="false" />
<set-property property="validationQuery" value="SELECT COUNT(*)
FROM usuario" />
</data-source>
</data-sources>
<form-beans >
<form-bean
name="UserLogin2Form"
type="com.gentaiw.struts.form.UserLogin2Form"/>
<form-bean
name="CrearUsuarioForm"
type="com.gentaiw.struts.form.CrearUsuarioForm"/>
<form-bean
name="EliminarUsuarioForm"
type="com.gentaiw.struts.form.UserLogin2Form"/>
<form-bean name="ConfigurarTestForm"
type="com.gentaiw.struts.form.ConfigurarTestForm" />
<form-bean name="MostrarUsuarioForm"
type="com.gentaiw.struts.form.MostrarUsuarioForm" />
</form-beans>
<global-exceptions />
<global-forwards >
<forward name="irLogin" path="/userLogin.jsp" />
<forward name="irInicio" path="/inicio.jsp" />
<forward name="irCrearUsuario" path="/crearUsuario.jsp" />
<forward name="irEliminarUsuario" path="/eliminarUsuario.do" />
<forward name="irActualizarUsuario" path="/actualizarUsuario.jsp" />
<forward name="irMostrarTest" path="/mostrarConfigurarTest.do" />
<forward name="irConfigurarTest" path="/configurarTest.jsp" />
<forward name="irAdminMenu" path="/adminLoginSuccess.jsp" />
<forward name="irUsuario" path="/mostrarUsuario.do" />
</global-forwards>
<action-mappings >
<action
path="/userLogin"
input="/userLogin.jsp"
name="UserLogin2Form"
scope="session"
attribute="listausuario"
type="com.gentaiw.struts.action.UserLoginAction"
validate="false">
<forward name="userlogin" path="/userLogin.jsp" />
<forward name="usuario" path="/userLoginSuccess.jsp" />
<forward name="admin" path="/adminLoginSuccess.jsp" />
</action>
<action
path="/crearUsuario"
input="/crearUsuario.jsp"
name="CrearUsuarioForm"
scope="session"
type="com.gentaiw.struts.action.CrearUsuarioAction"
validate="false">
<forward name="success" path="/usuarioCreado.jsp" />
</action>
<action
attribute="MostrarUsuarioForm"
name="MostrarUsuarioForm"
path="/mostrarUsuario"
scope="request"
type="com.gentaiw.struts.action.MostrarUsuarioAction"
validate="false">
<forward name="success" path="/mostrarUsuario.jsp" />
</action>
<action
input="/adminLoginSuccess.jsp"
path="/eliminarUsuario"
scope="request"
type="com.gentaiw.struts.action.EliminarUsuarioAction"
validate="false">
<forward
name="success"
path="/eliminarUsuario.jsp" />
</action>
<action
attribute="ConfigurarTestForm"
name="ConfigurarTestForm"
path="/mostrarConfigurarTest"
scope="request"
validate="false"
type="com.gentaiw.struts.action.MostrarConfigurarTestAction">
<forward name="success" path="/mostrarConfiguracionTest.jsp" />
</action>
<action
attribute="ConfigurarTestForm"
input="/configurarTest.jsp"
name="ConfigurarTestForm"
path="/configurarTest"
scope="request"
type="com.gentaiw.struts.action.ConfigurarTestAction"
validate="true">
<forward name="success" path="/configuracionGuardada.jsp" />
<forward name="error" path="/errorConfigurar.jsp" />
<forward name="input" path="/configurarTest.jsp" />
</action>
</action-mappings>
<message-resources
null="false"
parameter="ApplicationResources" />
<plug-in className="org.apache.struts.validator.ValidatorPlugIn">
<set-property property="pathname2" value="/WEB-INF/validation.xml" />
<set-property property="pathname1"
value="/WEB-INF/validator-rules.xml" />
</plug-in>
</struts-config>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]