Forums Register Login

Path on the webpage

+Pie Number of slices to send: Send
I'm using a form with action as

<form name="form1" Id="form1" method="post" action="/InstLayout/inServlet">

using this the page is directly directed to the servlet. I want to map the path on web.xml. How am I supposed to do that? Here, InstLayout is project name and inServlet is my servlet name.
+Pie Number of slices to send: Send
In your JSP, the action should be prefixed by the app context path which should never be hard-coded. See the JspFaq for more info, but in a nutshell:

where servlet-path is whatever is mapped in the deployment descriptor.

Please post your web.xml (be sure to UseCodeTags).
+Pie Number of slices to send: Send


Here, I'm done with my web.xml file and I don't want to hard code the path. How am I supposed to go about it.
+Pie Number of slices to send: Send
I already showed you the EL expression used to avoid hard-coding the context path.
My pie came with a little toothpic holding up this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 929 times.
Similar Threads
'The requested resource is not available' error
specifiying URI
Maintaining ActionForm data between Actions
prob in getParameter
Retrieve the Form action name
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 08:16:02.