Re: html servlet flow
- From: Jeff Kish <kishjjrjj@xxxxxxxxxxx>
- Date: Fri, 16 Jun 2006 22:44:37 -0400
On Fri, 16 Jun 2006 16:47:46 GMT, "Oliver Wong" <owong@xxxxxxxxxxxxxx>
wrote:
"Jeff Kish" <kishjjrjj@xxxxxxxxxxx> wrote in messageThanks Oliver.
news:ag34929iv6ciosf208sjg9tmh5l79ovuo2@xxxxxxxxxx
I'm still trying to get my head around what is going on between the
browser and Tomcat.
Still appreciate any elucidation, still studying.
The browser submits an HTTP request, and the server sends an HTTP
response. That response usually contains HTML, but it could respond with
anything (including images, flash animations, PDFs, etc.)
The server is free to send back any content it wants, and the browser is
free to submit any HTTP request it wants.
When writing websites, you have to provide enough information in your
responses so that the user can accomplish whatever tasks it is they want
done. You also have to take into account the fact that users are free to
send any request they want, and so you have to be able to handle
non-sensical requests and not assume requests will arrive in any particular
order or anything like that.
- Oliver
Is this right?
Say there is a hard coded jsp page, say:
mypage.jsp in the right dir under tomcat,
if the user types in the browswer address bar:
http://tomcat/jmypage.jsp
and presses return, then...
Then the browser packs up the 'mypage.jsp' and
formats it in the protocol of http, and send it to
the address (tomcat here).
Then tomcat recognizes the protocol, unpacks the
request, and sees "mypage.jsp".
Then it looks wherever it is legal for jsp pages to exist,
and starts processing the mypage.jsp?
If it is a simple page, it packs up the code/html in the jsp page into
the response and puts it in http format and sends it to the browser.
When the browser gets the response, it recognizes it is http, unpacks
it, and starts processing the html in the response.
And this 'response' isn't the response parameter in the doGet method,
it is just the general 'response' from the Tomcat.
Extra informatoin like headers etc are in the actual doget 'response'
variable.
Is this at all correct?
Thanks again
.
- Follow-Ups:
- Re: html servlet flow
- From: Oliver Wong
- Re: html servlet flow
- From: Mark Space
- Re: html servlet flow
- References:
- html servlet flow
- From: Jeff Kish
- Re: html servlet flow
- From: Jeff Kish
- Re: html servlet flow
- From: Oliver Wong
- html servlet flow
- Prev by Date: Re: download a file from jsp
- Next by Date: Re: SWT OpenGL
- Previous by thread: Re: html servlet flow
- Next by thread: Re: html servlet flow
- Index(es):
Relevant Pages
|