Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@apache.org Received: (qmail 75265 invoked from network); 16 May 2003 03:04:07 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 16 May 2003 03:04:07 -0000 Received: (qmail 20846 invoked by uid 97); 16 May 2003 03:06:22 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-user@nagoya.betaversion.org Received: (qmail 20839 invoked from network); 16 May 2003 03:06:22 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 16 May 2003 03:06:22 -0000 Received: (qmail 73828 invoked by uid 500); 16 May 2003 03:03:53 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Users List" Reply-To: "Tomcat Users List" Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 73815 invoked from network); 16 May 2003 03:03:53 -0000 Received: from smtp017.mail.yahoo.com (216.136.174.114) by daedalus.apache.org with SMTP; 16 May 2003 03:03:53 -0000 Received: from aliz122ly22tk.bc.hsia.telus.net (HELO d5uw0jc46ld8yk) (darylhandley72@207.6.7.156 with login) by smtp.mail.vip.sc5.yahoo.com with SMTP; 16 May 2003 03:04:02 -0000 From: "Daryl Handley" To: Subject: Forward to JSP from Servlet Date: Thu, 15 May 2003 21:05:30 -0700 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Hi all, When I forward to a JSP from a servlet, my JSP page is unable to find the resources (stylesheets, images, ....)it needs to display the page properly. The page comes up fine if I just type in the address of the JSP ... localhost/OnlineStore/jsp/index.jsp for example ... but if I forward to the page .... getsServletContext().getRequestDispatcher("/jsp/index.jsp").forward(req, res); ... it comes up with no stylesheets applied and none of my images are visible. I tried doing a res.sendRedirect and it worked fine (as I expected it too). I don't really want to use sendRedirect unless I have to since it has it's own problems. I'm assuming this has something to do with the servlet that is compiled from the jsp assuming the resources are going to be somewhere different, but I'm not really sure. I'm fairly new to Tomcat, but I used to do these kinds of forwards all the time using Websphere with no problem. Maybe there is some setting somewhere that I need to adjust ? Tomcat is v4.1.24 TIA Daryl --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-user-help@jakarta.apache.org