Explain http protocol in detail?
1) HTTP Protocol is an client server tcp based protocol.
2) Browser or client communicates with web server using http protocol.
3) Client sends the HTTP request and sends to the server.
4) The webserver receives the request and processes the request and generates the response. Continue reading
1) WebServer takes the client request and gives response back to the client.
2) Whenver the client sends request it can be static resource or it can be dynamic resource. Continue reading
Explain the important components of Webapplication?
1) Browser can be either internet explorer,Mozilla or safari.Browser is used to send the request to the server.
2) Webserver is the place where actual webapplication is deployed.Whenever browser sends request it sends it to the webserver.webserver gets the resource requested by client from DBMS or from any other external sources and gives the response back to the client. Continue reading
What is web application ?
Webapplication is collection of web pages which are generated in response to user requests.
A web page contains information.It may be either static content such as simple html page or it can contain dynamic content. Continue reading
1) Servlet config is used by servletcontainer to communicate to servlet.After init() method is called by servlet container ,it passes the servlet config object to the servlet.
2) The servletconfig contains information that we can pass to the servlet using deployment descriptor. Continue reading
Difference between Generic Servlet and HTTP servlet ?
|1) Generic Servlet is subclass of Servlet interface.
||1) Http Servlet is subclass of Generic Servlet.
|2) Generic servlets are protocol independent .It can access http,ftp etc
||2) Http Servlets are protocol dependent.It can access only http and https protocol. Continue reading
To capture the values from ui jsp or html page in servlet we use
getParameter accepts string values and returns Object if there is value else it returns null.
In this tutorial we will capture value from html page and display the captured value. Continue reading
We can configure servlet in two ways :
1) Using annotations
2) Deployment descriptor
Deployment descriptor is an xml document named web.xml that is deployed with application and contains configuration settings for application.In this tutorial we are discussing some of the mandatory elements that need to defined in web.xml. Continue reading
1) Java Servlets are efficient and powerful solution given by sun for creating dynamic content for the web.
2) Servlets are the main and central processing unit for web application
3) Java Servlets are designed to respond with dynamic content to client requests. Continue reading
Explain Servlet api and its methods ?
1) All Servlets must implement javax.servlet.Servlet interface either directly or indirectly.
2) Servlet container will create an instance of Servlet class and uses it to handle incoming requests.
3) Servlet interface defines methods that all servlets must implement.
4) Servlet class defines a contract between Servlet and Servlet container.