Hi, answers inlined.
On 14.09.2010 09:24 Antti Sykäri wrote: > Another thing I bumped into when playing with the calculator example and wanted > to make the URLs generated by Stripes prettier. > > I tried this (actually, with the URL "/calc"), but it the resulting page is not > found: > >> HTTP ERROR: 404 >> NOT_FOUND > (I first went to the page /test/calc.jsp, and then clicked 'Add'.) You need to configure the first part of the url in the web.xml if you want to use something other than "action". You could try this: @UrlBinding("/action/calc") Then try to open "/test/action/calc". This should work in your case. > Ideally, I'd like to name my UrlBinding to "/calc.jsp", since it is confusing > and > just plain wrong to have two URLs for one page. (Now both /test/calc.jsp and > /test/calc.action point to the same page.) If you call the jsp directly, you load it directly without entering a method in an action bean. The second url calls the default handler of the action bean - the one annotated with @DefaultHandler. If you have just one Method with the signature "public Resolution someName()", then you don't need the annotation and this method is invoked by Stripes. > But it then actions just do nothing > except reload the .jsp. It's as if the page doesn't go through Stripes at all. > Perhaps that's what actually is happening. They go through Stripes because you get a result with the call of calc.action And last but not least: I never tried to change the action bean suffix to ".jsp". Maybe it can work, but I think that you won't be able to load the real JSPs directly any more. But that is just a guess. Personally, I usually move my JSPs in a subfolder within WEB-INF and load them via custom actions. This way, they can never be called directly from a web browser, and I avoid URL mixture (sometimes seeing .jsps, sometimes .actions). HTH, Marcus ------------------------------------------------------------------------------ Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev _______________________________________________ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users