What does the index action look like? What does it return? And what's in /jsp/index.jsp? It's not just a copt of /index.jsp is it, with the same redirect directive...? ;-)

L.

Karr, David wrote:
Note that the "index.jsp" at the root of the webapp looks like this:

        <% response.sendRedirect("index.action"); %>

The action that this refers to is:

  <action name="index" class="com.fdar.apress.s2.IndexAction">
    <result>/jsp/index.jsp</result>
  </action>

For some reason, instead of going to "/jsp/index.jsp", it appears to be
trying to serve "/index.jsp", which seems to be what causes the infinite
loop.

Martin Gainty pointed out to me that I was missing the "actionPackages"
init-param.  I fixed that, but that only made it so that it made it into
my "index" action class, 20 times before failing.

I tried enabling "devMode" in the struts.properties file and sending
"?debug=console" to my URL, but that didn't appear to give me any
additional info anywhere.

-----Original Message-----
From: Karr, David Sent: Tuesday, March 04, 2008 12:37 PM
To: Struts Users Mailing List
Subject: Index.jsp hit 20 times and fails with "The page isn't redirecting properly"

I'm trying to piece together the app described in chapter 2 from the Practical Apache Struts book (just from the soure code zip). I have
Struts2.0.11 and Tomcat 6.0.14.

After I got to the point where it appeared to deploy without errors, when I execute the URL, the browser returns "The page isn't redirecting properly". I put a print statement at the root "index.jsp" which shows that "index.jsp" is getting hit 20 times on initial entry, before I get the "The page isn't redirecting properly" error. It never got into any of my action code.

What could I be doing wrong?

If it helps, I'll attach my web.xml and struts.xml.



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to