I tried to forward to loginPage.page from the action and it is working fine, but i remember that I can request the page directly... any suggestion?
On 4/9/06, Yang Sun <[EMAIL PROTECTED]> wrote: > > I think you should add an action in the action-mappings section for > loginPage action. You request have not been processed by tiles yet. > > // Yang > > On 4/9/06, Ahmed Hashim <[EMAIL PROTECTED]> wrote: > > > > what is wrong with this configuration? > > <?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 /> > > > > <form-beans> > > <form-bean name="loginForm" type="evote.form.LoginActionForm"> > > </form-bean> > > </form-beans> > > > > <global-exceptions /> > > <global-forwards /> > > > > <action-mappings> > > > > > > </action-mappings> > > <controller processorClass=" > > org.apache.struts.tiles.TilesRequestProcessor" > > /> > > > > <message-resources parameter=" > evote.struts.language.ApplicationResources > > " > > /> > > <plug-in className="org.apache.struts.tiles.TilesPlugin"> > > <set-property property="definitions-config" value="/WEB-INF/tiles- > > def.xml"/> > > <set-property property="definitions-debug" value="2" /> > > <set-property property="definitions-parser-details" value="2" /> > > <set-property property="definitions-parser-validate" value="true" /> > > <set-property property="moduleAware" value="true" /> > > </plug-in> > > > > </struts-config> > > > > > > <?xml version='1.0'?> > > <!DOCTYPE tiles-definitions PUBLIC "-//Apache Software Foundation//DTD > > Tiles > > Configuration 1.1//EN" " > > http://jakarta.apache.org/struts/dtds/tiles-config_1_1.dtd"> > > <tiles-definitions> > > <definition name="genericLayout" path="/jsp/layout/layout.jsp"> > > <put name="title" value="Electronic Voting System" /> > > <put name="menu" value="/jsp/layout/menu.jsp" /> > > <put name="header" value="/jsp/layout/header.jsp" /> > > <put name="footer" value="/jsp/layout/footer.jsp" /> > > <put name="body" value="/jsp/layout/body.jsp" /> > > </definition> > > > > <definition name="loginPage.page" extends="genericLayout"> > > <put name="body" value="/jsp/login.jsp" /> > > </definition> > > </tiles-definitions> > > > > <?xml version="1.0" encoding="UTF-8"?> > > <web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi=" > > http://www.w3.org/2001/XMLSchema-instance" version="2.4" > > xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee > > http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> > > <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> > > <init-param> > > <param-name>debug</param-name> > > <param-value>3</param-value> > > </init-param> > > <init-param> > > <param-name>detail</param-name> > > <param-value>3</param-value> > > </init-param> > > <load-on-startup>2</load-on-startup> > > </servlet> > > <servlet-mapping> > > <servlet-name>action</servlet-name> > > <url-pattern>*.do</url-pattern> > > </servlet-mapping> > > > > </web-app> > > > > when i try to request http://localhost:8080/Evote/loginPage.do i got the > > message SEVERE: Invalid path /loginPage was requested > > > > what do you think the problem? > > > > -- > > In Life, it doesn't matter who you are, but whether someone appreciates > > you > > for what you are, accepts you and loves you unconditionally. A Real > Friend > > ( > > Friendship ) is one who walks in when the rest of the world walks away. > > > > -- In Life, it doesn't matter who you are, but whether someone appreciates you for what you are, accepts you and loves you unconditionally. A Real Friend ( Friendship ) is one who walks in when the rest of the world walks away.