Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Struts 2 »

Re: <html:link forward="search"> causing Exception in JSP

Patrick Grimard

2007-01-18

Replies:

That didn't work. I did however take a closer look at my struts-config.xml. I
happened to find in my action mapping my type was
"com.jamesholmes.minihr/SearchAction", I replace the "/" with "." and now it
doesn't give me JSP exception, now it just gives me:

type Exception report


message


description The server encountered an internal error () that prevented it from
fulfilling this request.


exception


org.apache.jasper.JasperException: Module 'null' not found.

org.apache.jasper.servlet.JspServletWrapper.handleJspException (JspServletWrapper.java:512)


org.apache.jasper.servlet.JspServletWrapper.service (JspServletWrapper.java:395)

org.apache.jasper.servlet.JspServlet.serviceJspFile (JspServlet.java:314)
        org.apache.jasper.servlet.JspServlet.service (JspServlet.java:264)
        javax.servlet.http.HttpServlet.service (HttpServlet.java:802)



root cause


java.lang.NullPointerException: Module 'null' not found.

org.apache.struts.taglib.TagUtils.getModuleConfig (TagUtils.java:743)

org.apache.struts.taglib.TagUtils.computeURLWithCharEncoding (TagUtils.java:360)

org.apache.struts.taglib.TagUtils.computeURLWithCharEncoding (TagUtils.java:281)

org.apache.struts.taglib.html.LinkTag.calculateURL (LinkTag.java:433)
        org.apache.struts.taglib.html.LinkTag.doStartTag (LinkTag.java:315)
        org.apache.jsp.index_jsp._jspx_meth_html_link_0(index_jsp.java:123)
        org.apache.jsp.index_jsp._jspx_meth_html_html_0(index_jsp.java:96)
        org.apache.jsp.index_jsp._jspService(index_jsp.java:57)
        org.apache.jasper.runtime.HttpJspBase.service (HttpJspBase.java:97)
        javax.servlet.http.HttpServlet.service (HttpServlet.java:802)

org.apache.jasper.servlet.JspServletWrapper.service (JspServletWrapper.java:334)

org.apache.jasper.servlet.JspServlet.serviceJspFile (JspServlet.java:314)
        org.apache.jasper.servlet.JspServlet.service (JspServlet.java:264)
        javax.servlet.http.HttpServlet.service (HttpServlet.java:802)



note The full stack trace of the root cause is available in the Apache
Tomcat/5.5.20 logs.

Patrick Grimard
M.I.S.
XTL Transport Inc.
T. (514) 636-1499 Ext. 5991
T. (800) 636-2138 Ext. 5991
F. (514) 636-5700


                                                   
        "Pierre Thibaudeau"                                
        <pierre.thibaudeau@                                
        gmail.com>                                    To
                          "Struts Users Mailing List"        
        01/18/07 02:58 PM       <user@(protected)>          
                                                  cc
                                                   
        Please respond to                           Subject
          "Struts Users        Re: <html:link forward="search">    
          Mailing List"        causing Exception in JSP          
        <user@(protected)                                
            .org>                                    
                                                   
                                                   
                                                   
                                                   




I believe your global forward should point onto /search.do (which is the
ActionMapping whose path is defined as "/search" further down in your
struts-config.xml:

<global-forwards>
  <forward name="search" path="/search.do"/>
</global-forwards>

Everything else in your struts-config-xml seems to be fine. Does that help?


2007/1/18, Patrick.Grimard@(protected)>:
>
>  <!-- Global Forwards Configuration -->
>  <global-forwards>
>   <forward name="search" path="/search.jsp"/>
>  </global-forwards>
>




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)

©2008 junlu.com - Jax Systems, LLC, U.S.A.