What are the uses of Servlets

Servlets are implemented using java language so these have platform independent feature. These are faster than CGI These have declarative security management feature It is server side component,so servlets inherit the security provided by web server Servlets are a key component in Java for developing web applications. They are server-side programs that run on the … Read more

What is a Servlet

Servlet is server side component, a servlet is small pluggable extension to the server. Servlets are used to extend the functionality of the java-enabled server. Servlets will be loaded in theAddress space of web server. Servlet can be loaded in 3 ways When the web sever starts. You can set this in the configuration file. … Read more

What Happens when the index.jsp Page is Requested by the Client, if this page included instance variable and included in another jsp page. .

A JSP Page, Include.jsp, has a Instance Variable “int a”, now this Page is Statically Included in Another JSP Page, index.jsp, which has a Instance Variable “int a” Declared. What Happens when the index.jsp Page is Requested by the Client. Compilation error, as two variables with same name can’t be declared. This happens because, when … Read more

What Happens when a Page is Statically Included in Another JSP Page

An include directive tells the JSP engine to include the contents of another file (HTML, JSP, etc.) in the current page. This process of including a file is also called as static include. When a page is statically included in another JSP page in Java, it means that the content of one JSP page is … Read more

Why is _jspService() Method Starting with an ‘_’ while other Life Cycle Methods do not?

jspService() method will be written by the container hence any methods which are not to be overridden by the end user are typically written starting with an ‘_’. This is the reason why we don’t override _jspService() method in any JSP page. In JavaServer Pages (JSP), the _jspService() method is a special method that handles … Read more