Answer Posted / balu
we cant use servlets in javascript but we can call a
servlet by retrieving the form and setting the action as
the url.
ex:if our html has a from named 'XXX'
var formName = document.getElementById('XXX');
var url = contextPath + '/desiredServlet';
formName.action = url;
formName.submit();
Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
What do you mean by web applications?
What is servlet api used for conneting database?
Explain load on start-up and its importance?
Can you send an authentication error from a servlet?
What are the features added in Servlet 2.5?
Explain servlet events?
What is url encoding and url decoding
Explain the difference between generic servlet and http servlet?
How can you create a session in servlet?
What is servlet initializer?
Can we use the constructor, instead of init(), to initialize servlet?
What are the steps involved in placing a servlet within a package?
What is servlet attributes and their scope?
Which httpsession object is used to view and manipulate information about a session?
What are the types of an http request?