aspose file tools*
The moose likes Servlets and the fly likes jsp -> Servlet -> jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "jsp -> Servlet -> jsp" Watch "jsp -> Servlet -> jsp" New topic
Author

jsp -> Servlet -> jsp

Scott Minor
Greenhorn

Joined: Nov 05, 2001
Posts: 5
I have the following problem that I have been working on for several days and I can't find an answer to it anywhere.
I have a JSP page that gets loaded when the user enters the site. Depending on what the user selects it is sent them to a servlet and the servlet processes the request and then forwards to a new JSP. The problem that I have is that when the JSP that is forwarded to I don't get my images or my style sheets.
I am using an include for the header, menu and footer. I get all of the items but not formatted correctly because I am not getting back to the root of the wed server after I call the servlet.
Thanks for the help.
Tony Alicea
Desperado
Sheriff

Joined: Jan 30, 2000
Posts: 3222
    
    5
The root of the Web server may be different from the WEB APPLICATION context or "root".
Usually the style sheets and images etc should be accessible from the application context. Or you can try using fully qualified URLs like http:///www.myserver.com/images/hello.gif. Same for style sheets.


Tony Alicea
Senior Java Web Application Developer, SCPJ2, SCWCD
Scott Minor
Greenhorn

Joined: Nov 05, 2001
Posts: 5
Tony,
I have everything in the right directories because I have a default.jsp file that is in the root. It includes all of my other JSP's and images that are needed. This page is displayed correctly when rendered. The page that the servlet forwards to is also in the root. It is actually a copy of index.jsp renamed. I just want to see it work.
I am using IBM WebSphere v3.5.3.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jsp -> Servlet -> jsp
 
Similar Threads
problem using javabean in JSP
Problem retrieving session value in jsp pagess
Urgent -RequestDispatcher.include and forward
JSP Compiling and session issue
use diffrent servlet values (how to unload a servlet)