In the future please ask
one question per topic.
Popescu Ion wrote:I had created a servlet, named "Download" , package: "servlets".
What is the expresion for calling the servlet from a jsp page, let's say index.jsp?
You don't "call" servlets, so I'm not sure what you are trying to do. Generally, there will be a link or form on the page that invokes the servlet via its URL.
And if I do something like this :
it will be initializate in the general servlet or my Download servlet, or both ?
That will have nothing whatsoever to do with your servlet. All it will do is to assign a
string to an instance variable.
By the way, putting
Java code in a JSP is an extremely poor practice that has been discredited for almost 10 years now. Why are you doing it?