Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

servlet question

Posted on 1998-04-23
5
Medium Priority
?
257 Views
Last Modified: 2013-11-24
Hi folks,
I am not sure whether I should put this question here. But I could not find any other place. I am writing
a java servlets using JDK 1.1.5 and JSDK 1.0.1. Instead of using servlet enabled Web server, I am using
srun.exe ( standalone servlet -runner that comes with JSDK1.0.1). In the servlet, I am generating html
dynamically. In the html, I am loading a image(.gif) file. The problem is the browser cannot find the gif
file though it is in the same directory from where I am running srun. I can access servlet from the directory,
but not gif. How can I do it?? I tried giving absolute path like http://maha-pc:8080/servlet/title.gif in the html.
Still it did not work. The documentation does not say anything. Has anybody tried it ??

Thanx
Maha
0
Comment
Question by:maha
  • 2
  • 2
5 Comments
 

Expert Comment

by:sdaxm11
ID: 1219507
could you post the servlet ?
0
 

Author Comment

by:maha
ID: 1219508
yes, I can do eveything except that I can't load the image file.

0
 

Expert Comment

by:sdaxm11
ID: 1219509
no, can you post or email me the servlet (code) at miss.jones@mcmail.com
0
 

Accepted Solution

by:
acidburn earned 0 total points
ID: 1219510
This is an HTTP question, not a java question really.

Only executable objects (serialized objects or class files) may be served by srun.  You need to run an HTTPD server.  I suspect that if you telneted to your box with
      telnet localhost 80

and tried to access the document manually with
      GET /servlet/title.gif HTTP/1.0

It would definately fail to respond with the appropriate gif. I don't know what platform you are running on but you might be able to run a simple webserver of any type, along with srun on another port #, in order to fully accomplish what you are trying to do.

...Acidburn...

0
 

Author Comment

by:maha
ID: 1219511
Thanx acidburn,

I got it worked using IIS server and srun.

Maha
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

971 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question