|
|
 |
| JSP Basics Beginning-level questions on JSP. More advanced coders should post to Pro JSP. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the JSP Basics section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.
|
 |

January 21st, 2004, 08:28 AM
|
|
Registered User
|
|
Join Date: Sep 2003
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Root Cause:java.lang.NoSuchMethodError: java.util.
i am using Tomcat4.0 and Struts 1.1, and i am getting following Error when i run my application. Can anyone help me regarding this problem.
thanks in advance
Root Cause:
java.lang.NoSuchMethodError: java.util.logging.Logger.logp(Ljava/util/logging/Level;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
at org.apache.commons.logging.impl.Jdk14Logger.log(Jd k14Logger.java:126)
at org.apache.commons.logging.impl.Jdk14Logger.info(J dk14Logger.java:193)
at org.apache.struts.util.PropertyMessageResources.(P ropertyMessageResources.java:127)
at org.apache.struts.util.PropertyMessageResourcesFac tory.createResources(PropertyMessageResourcesFacto ry.java:90)
at org.apache.struts.util.MessageResources.getMessage Resources(MessageResources.java:577)
at org.apache.struts.action.ActionServlet.initInterna l(ActionServlet.java:1329)
at org.apache.struts.action.ActionServlet.init(Action Servlet.java:464)
at javax.servlet.GenericServlet.init(GenericServlet.j ava:366)
at org.apache.catalina.core.StandardWrapper.load(Stan dardWrapper.java:856)
at org.apache.catalina.core.StandardWrapper.allocate( StandardWrapper.java:621)
at org.apache.catalina.core.StandardWrapperValve.invo ke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardPipeline.invokeNe xt(StandardPipeline.java:566)
at org.apache.catalina.core.StandardPipeline.invoke(S tandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(Cont ainerBase.java:943)
at org.apache.catalina.core.StandardContextValve.invo ke(StandardContextValve.java:215)
at org.apache.catalina.core.StandardPipeline.invokeNe xt(StandardPipeline.java:566)
at org.apache.catalina.valves.CertificatesValve.invok e(CertificatesValve.java:246)
at org.apache.catalina.core.StandardPipeline.invokeNe xt(StandardPipeline.java:564)
at org.apache.catalina.core.StandardPipeline.invoke(S tandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(Cont ainerBase.java:943)
at org.apache.catalina.core.StandardContext.invoke(St andardContext.java:2366)
at org.apache.catalina.core.StandardHostValve.invoke( StandardHostValve.java:164)
at org.apache.catalina.core.StandardPipeline.invokeNe xt(StandardPipeline.java:566)
at org.apache.catalina.valves.AccessLogValve.invoke(A ccessLogValve.java:462)
at org.apache.catalina.core.StandardPipeline.invokeNe xt(StandardPipeline.java:564)
at org.apache.catalina.core.StandardPipeline.invoke(S tandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(Cont ainerBase.java:943)
at org.apache.catalina.core.StandardEngineValve.invok e(StandardEngineValve.java:163)
at org.apache.catalina.core.StandardPipeline.invokeNe xt(StandardPipeline.java:566)
at org.apache.catalina.core.StandardPipeline.invoke(S tandardPipeline.java:472)
at org.apache.catalina.core.ContainerBase.invoke(Cont ainerBase.java:943)
at org.apache.catalina.connector.http.HttpProcessor.p rocess(HttpProcessor.java:1005)
at org.apache.catalina.connector.http.HttpProcessor.r un(HttpProcessor.java:1098)
at java.lang.Thread.run(Unknown Source)
|

January 21st, 2004, 08:44 AM
|
|
Friend of Wrox
|
|
Join Date: Jun 2003
Location: , , .
Posts: 175
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Is it something simple; like not importing the java.util.logging.Logger class?
Cheers
Martyn
|

January 22nd, 2004, 01:49 AM
|
|
Registered User
|
|
Join Date: Sep 2003
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
No martyn i did try that but that did't solved my problem.
ok this is my action class code:
package Classes;
import java.util.logging.Logger;
import javax.servlet.ServletContext;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
public class AddBookAction extends Action
{
public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request,HttpServletResponse response)
{
ServletContext ctx = servlet.getServletContext();
Catalog catalog = (Catalog)ctx.getAttribute("catalog");
ShoppingCart cart = (ShoppingCart)form;
int book = Integer.parseInt(request.getParameter("index"));
cart.addBook((Book)catalog.get(book));
return mapping.findForward("success");
}
}
Regards:
Anees
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
 |