Win a copy of Microservices Testing (Live Project) this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

has it got to do with WSAD5.1.2

 
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

Ive read quite a few posts where people have mentioned that "after removing .do from the jsp's it is working fine". I know that struts appends the .do to the path mentioned in the form tag. But im not convinced that if you append .do yourself it wont work.I am using WSAD 5.1.2 and in all my jsp's im appending .do to my paths like:



And yes I am using Struts tags. Can anyone tell me why it is working in my case and not with others?Is it because of WSAD?
 
Ranch Hand
Posts: 354
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
it's not WSAD. it's most likely your web.xml not having the proper servlet mapping for struts. you probably have something like


<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.*</url-pattern>
</servlet-mapping>


which makes EVERYTHING (bad, bad, slap) go through the action servlet. the correct url-pattern is *.do. see http://www.learntechnology.net/struts-lesson-1.do (web.xml section).
 
dnyan ginde
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My web.xml is correct.

Any idea why it is working for me with .do and not for others.
 
I am mighty! And this is a mighty small ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic