to fontaine!

Posted on 1998-07-02
Last Modified: 2010-03-30
You told me my applet was running on your machine.
What did it do?
I load my applet from the server, here it's ok.
But the word which is enter is not reversed.
The answer in the textarea is (I use pause method for read):
        http/1.0 400 Mauvaise demande
then  Content-Type : text/html
then  nothing
then  <body><h1>http/1.0 400 Mauvaise demande
then  </h1><body>
the end.
I don't no where it find these marks because I don't have <h1> but <hr>.
I submit this question one time again:
"The server program is running on the server. Is it enough?
Is it necessary for the server program to be from the same directory as the loaded applet?".
I don't have any good answer for this question.
And you, how do you make this program running?

It is no more necessary to turn the applet in an application.
Thank you for your help.
Question by:joac
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 9
  • 4

Author Comment

ID: 1224440
Edited text of question

Author Comment

ID: 1224441
Edited text of question

Expert Comment

ID: 1224442
Could you give me the link to the previous question, so that I can refresh my mind?
Independent Software Vendors: 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!


Author Comment

ID: 1224443
today I am joac, tomorow i will be thibal...
I want to test a program that i found in "Java in a nutshell"

Author Comment

ID: 1224444
My questions where "Couldn't connect to"
I work on a LAN with an NT server.

Author Comment

ID: 1224445
Edited text of question

Accepted Solution

fontaine earned 50 total points
ID: 1224446
I think that I see what happens. HTTP 400 means that the HTTP server has received a
request that it couldn't understand due to a malformed syntax. If you have it in the applet,
this means are connecting to the HTTP server from within the applet and not to
the server you wrote. Assuming you are using the code of the last question, here is how
to set up the whole stuff to work:

- on your NT server machine, start the "reverse string" server. It is listening on port 1548.
- put the applet in the "pages" directory of the Web server (that part seems ok).

The Web server serves the HTML page and starts the applet. The applet deduces the host
name of the server machine using the host name of the Web server that served it and
connects to the "reverse string" server listening on port 1548. I have the feeling that in your
applet, you are using the port dedicated to the Web service (80, probably). That's the
mistake: it has to be port of the "reverse string" server, not the one of the Web server.

Author Comment

ID: 1224447
When I run the server, there is not any information like
"Server:listening on port XX". there is a system.out.println with this sentence. Is it normal?


Author Comment

ID: 1224448
I have choose 1548 at random for the port number.
Could it be a reserved port number for a specific service?

Expert Comment

ID: 1224449
I have it, here. Be sure that you can use the port 1548. Shut down your server and see
if another server is already on that port using a telnet:

telnet 1548

if the connection succeeds, the port is already in use.


Author Comment

ID: 1224450
My applet is in the pages directory of the Web server (I can load it on the client machine).The port number is 1548 in the code.
You said that you think my applet is served by the HTTP server?
It could be due to an operation of the applet which make port=0?


Expert Comment

ID: 1224451
Your applet has to be served by the HTTP server, but the request sent from within the applet
has to be sent to the server you wrote, i.e on, port 1548. Just after
having created the socket, output socket.toString() and post the result here. I think that could
be useful.

Author Comment

ID: 1224452
I try running the server with the jview.exe and then it is running. I am very happy! thank you for your fast help since three weeks. No I will try to adapt this program to my own project.
I will be happy to find you on the Net answering my question!
     joac le francophone.

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
iterator/ListIterator approach 17 66
String array comparison 4 55
Chrome and Firefox Java 5 88
JAVA API design with micro service cloud in mind 1 108
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses

738 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