• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

about web project URL

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear sir:
my current web project  url is http://localhost:8080/BSP/adm.login.login.action
but when i type http://localhost:8080/BSP/123/adm.login.login.action , it still show correct info ,
not http 404 not found  message , why and how can i resolve this problem ? thank for helping
 
Sheriff
Posts: 22781
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please TellTheDetails. Can you show us the content of your web.xml file?
 
tung lee
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
here is my web.xml ,should i need to declare  uri-pattern ?
-------------------------------------------------------------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WMS" version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
<display-name>WMS</display-name>

  <servlet>
       <servlet-name>mvc-dispatcher</servlet-name>
       <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
       <init-param>
           <param-name>contextClass</param-name>
           <param-value>
           org.springframework.web.context.support.AnnotationConfigWebApplicationContext
       </param-value>
       </init-param>      
   </servlet>

   <!-- freemarker -->
   <servlet>
       <servlet-name>JspSupportServlet</servlet-name>
       <servlet-class>org.apache.struts2.views.JspSupportServlet</servlet-class>
       <load-on-startup>1</load-on-startup>
   </servlet>

   <context-param>
       <param-name>contextInitializerClasses</param-name>
       <param-value>com.bi.base.spring.BIApplicationContextInitializer</param-value>
   </context-param>
   
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>
classpath*:spring/ApplicationContext*.xml
</param-value>
</context-param>

<filter>
<filter-name>characterEncodingFilter</filter-name>
<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
<init-param>
<param-name>encoding</param-name>
<param-value>UTF-8</param-value>
</init-param>
<init-param>
<param-name>forceEncoding</param-name>
<param-value>true</param-value>
</init-param>
</filter>

<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>
</filter>
   <filter>
       <filter-name>bodyRepeatReadFilter</filter-name>
       <filter-class>com.bi.spring.rest.server.filter.RequestBodyRepeatReadFilter</filter-class>
   </filter>
<filter-mapping>
<filter-name>characterEncodingFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
 
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<listener>
<!--
This will always be the first listener. Introspector is used in both
common-dbutils and BI-BASE
-->
<listener-class>org.springframework.web.util.IntrospectorCleanupListener</listener-class>
</listener>
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
<listener>
<listener-class>org.springframework.web.context.request.RequestContextListener</listener-class>
</listener>
<!--
<servlet> <servlet-name>WmpStartup</servlet-name>
<servlet-class>com.bi.util.StartUp</servlet-class>
<load-on-startup>1</load-on-startup> </servlet>
-->

   <!-- to disable EL in JSP 2.1 and allow '#' to work properly in Struts2/OGNL -->
<jsp-config>
<jsp-property-group>
<url-pattern>*.jsp</url-pattern>
<el-ignored>true</el-ignored>
</jsp-property-group>
</jsp-config>

<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
<welcome-file>index.html</welcome-file>
</welcome-file-list>

<error-page>
       <error-code>404</error-code>
       <location>/error.serverError.action</location>
</error-page>
<error-page>
   <error-code>500</error-code>
   <location>/error.serverError.action</location>
</error-page>
</web-app>
 
reply
    Bookmark Topic Watch Topic
  • New Topic