Find Interview Questions for Top Companies
Ques:- can i use vb script with jsp?
Comments
Admin May 17, 2020

Yes, of course you can use VBScript in JSP.
Scripts are client side stuffs n are not related to server
side components like JSP or servlets.
But VBScript is supported on a very limited browser(like IE).
So your JSP may not work on other browsers like mozilla
firefox n all.
So better check out what browser ur customers are going to
use and the use either VBscript or javascript.

Admin May 17, 2020

I'm not sure what you mean by "VBScript with JavaScript" -
mixing both on a single page?-, but VBScript is limited to
one particular browser on one particular operating system,
so you'd be shutting out a lot of users from your
application.

Ques:- what is the enitre process of using smart forms to create forms?
Comments
Admin May 17, 2020

As per me smart form means reproduce the same form by
clicking '+' sign button etc.
It can be possibe with jquery.

Ques:- sample program for reading mails from inbox with file attacchments in servlet
Asked In :- Addverb Technologies,
Ques:- we want to provide the errors to the right side of the text field so what we want to add in jsp pages?
Asked In :- first derivatives, tescra,
Comments
Admin May 17, 2020

first tell me hows ur structure in jsp page ::::

Ques:- How to find the hidden answers present in an online exam?
Comments
Admin May 17, 2020

It depends on the web application.
If it stores the answer on the client page(html /jsp page)
then u can see the source and using any javascript/vbscript
can write a script to show the element's value.
But if ur input is checked on the server side then u can't
do anything..(n this is what generally done)

Admin May 17, 2020

Ask the person who prepared those questions.

Ques:- Explain about the Scriplet and Exclamatory Tag?
Asked In :- afour technologies,
Comments
Admin May 17, 2020

Scriplet tag is one of the JSP tag, it will replicate the
entire code in the service method.
In the exclamatory Tag, you can define the Global variables
and write the user defined methods.

Ques:- what is difference between redirect and forward method?
Comments
Admin May 17, 2020

In sendRedirect new request is generated forwarded to the
specified page.where as in forward old reuest is forwarded
to the specifed page

Ques:- How to implement a thread-safe jsp page?
Comments
Admin May 17, 2020

isThreadSafe sattes that wheather jsp engine can pass
multiple req simultaneously to the page . a value set to
true(default) indicates that a new thread is started and
therfore request are handled simultaneously . ise the jsp
engine can send multiple concurent lient request to the jsp
page . value set to false indicates that jsp engine sends
lient request one at a time to the jsp page .
It is recommended to always use the value tue for the is
threadsafe page directive and handled multithread issue
by avoiding jsp declaration and ensures that all object
used by the page are thread safe.
Syntex
<% page isthreadSafe="true"%>

Admin May 17, 2020

just add the directive <%@ page isThreadSafe="false" %>
with the jsp page..

Ques:- how to enable session tracking for jsp pages,if the browser has disabled cookies?
Comments
Admin May 17, 2020

using url rewriting.

Admin May 17, 2020

We have to use URL Rewriting for tracking sessions if
cookie is disabled..we are mentioning the session id here..

Ques:- What is the difference between and sendRedirect?
Comments
Admin May 17, 2020

Using <jsp:forward> you can forward the request and
response object to the concern URL. Where as in
sendRedirect, it will not carry the request and response
object details.

Admin May 17, 2020

Forwrd :: when we invoke forward the request is sent to the
another resource on the server without the client being
inform that difference resource is going to process that
request.
SendRedirect :: when we invoke sendRedirect, It causes the
web container to return to the brouser that means new URL
should be requested.
SendRedirecr takes extra round trip
Forward is fater than sendRedirect

Ques:- How many page directive we can use in a single JSP?
Asked In :- Braves Technologies,
Comments
Admin May 17, 2020

language
import
session
buffer
isThreadSafe
ErrorPage
isErrorPage
Info
contentType
pageEncoding
isELIgnore
autoflush

Admin May 17, 2020

We can have any number of page directive in a single jsp
page provided it should have only 'import' attribute.
e.g.
<%@ page import="beans.abc" buffer="2k"%> //1
.
.
.// some jsp page code
.
<%@ page import="beans.xyz"%> //2
if we replace line 2 with
<%@ page import="beans.xyz" buffer="4k"%> //not allowed
In short, we can use page directive many times but for
importing some other classes, not for setting other
attribute values.

Ques:- Can we use methods in JSP? If so where the methods are stored in servlet class file?
Comments
Admin May 17, 2020

Yes we can write java methods inside jsp files within
the "declarations" tag <!%//the method%>.
This part of the code is compiled by the servlet engine and
inserted outside the _jspservice() method in the generated
servlet class.

Admin May 17, 2020

<%!
action-specifier return type methodname(arguemnts)
{
statements.............or task
}
%>

Ques:- How to set a cookie in JSP?
Asked In :-
Comments
Admin May 17, 2020

<%
Cookie mycookie = new Cookie("aName","aValue");
response.addCookie(mycookie);
%>

Ques:- How can a cookie is deleted with JSP?
Asked In :- DigiQ Solutions,
Comments
Admin May 17, 2020

<%
Cookie killMyCookie = new Cookie("mycookie", null);
<%-- mycookie is the cookie instance which we have to
delete%>
killMyCookie.setMaxAge(0);
killMyCookie.setPath("/");
response.addCookie(killMyCookie);
%>

Ques:- What are JSP scripting elements?
Asked In :- Renault Nissan, Octro, eleks,
Comments
Admin May 17, 2020

Scriptlet, expression and declaration are called JSP
scripting elements.

Admin May 17, 2020

<%....%>scriptlet , embeding scripting code
<%=...%>expression
<%!....%> declaration

Ques:- How are Servlets and JSP Pages related?
Asked In :- Magic Software,
Comments
Admin May 17, 2020

Relationof servlet and JSP is
RequestDispatcher reqdip=req.RequestDispatcher("sum.jsp");
forward.req(req,res)

Admin May 17, 2020

Jsp pages are focussed around HTML (or XML) with java codes
and JSP tags inside them.When a web server that has JSP
support is asked for a JSP page,it checks to see if it has
already compiled the page into a servlet.Thus ,JSP pages
become servlets and are transformed into pure Java and then
compiled,loaded into the server and executed.

Ques:- What are JSP Directives?
Asked In :- PureSoftware,
Comments
Admin May 17, 2020

A directive is a way for you to give special instruction to
the container at page translation time.
3 flavours
page
include
taglib

Admin May 17, 2020

1)page directive
2)include directive
3)taglib directive

Ques:- What are implicit objects?
Asked In :- Allied Softech, TietoEVRY,
Comments
Admin May 17, 2020

one more implicit object availbale in JSP: exception

Admin May 17, 2020

To simplify code in JSP expressions and scriptlets, we can
use eight automatically defined variables, called implicit
objects.
They are
request,response,out,session,application,config,pageContext
and page.

Ques:- What are JSP ACTIONS?
Comments
Admin May 17, 2020

Action tag is used to transfer the control between pages
and is also used to enable the use of server side
JavaBeans. Instead of using Java code, the programmer uses
special JSP action tags to either link to a Java Bean set
its properties, or get its properties.
There are many action tags that are available for Java
Server Pages. The most commonly used action tags are three
of them and they are namely:
include
forward
useBean

Admin May 17, 2020

JSP actions use constructs in XML syntax to control the
behavier of the servlet engine.you can dynamially insert a
file, reuse Java Beans Components,forward the user to
another page,or generate HTML for the java plugin.Available
actions include:
jsp:include,jsp:useBean,jsp:setProperty,jsp:getProperty,jsp:forward,jsp:plugin

Ques:- What is difference between custom jsp tags and beans?
Asked In :-


The Java skill section on takluu.com is designed for freshers, intermediate developers, and experienced professionals aiming to crack Java-based technical interviews with confidence. Java remains one of the most in-demand programming languages, and mastering it opens the door to countless opportunities in backend development, enterprise solutions, Android apps, and cloud-based platforms.

Our Java category covers everything from Core Java concepts like OOPs (Object-Oriented Programming), Data Types, Loops, and Exception Handling to Advanced Java topics including Collections Framework, Multithreading, JDBC, Servlets, JSP, Lambda Expressions, and Streams. We provide practical coding examples, real interview questions (with answers), and key concept explanations that interviewers commonly test.

Whether you’re applying for a role like Java Developer, Backend Engineer, or Full Stack Developer, this section ensures you understand the logic, syntax, and problem-solving approaches that matter in real-world interviews. You’ll also find scenario-based questions and discussions around design patterns, JVM internals, garbage collection, and performance tuning — areas often explored in senior-level interviews.

Each topic is structured to help you revise quickly and efficiently, with quizzes and mock interviews to assess your understanding. Our content is curated by experts who have worked with Java across different domains and keep the material aligned with current industry trends.

At Takluu, we believe in not just learning Java — but preparing to think in Java. Get ready to face interviews with clarity, confidence, and a deep understanding of what makes Java so powerful and reliable.

AmbitionBox Logo

What makes Takluu valuable for interview preparation?

1 Lakh+
Companies
6 Lakh+
Interview Questions
50K+
Job Profiles
20K+
Users