Organizational Research By

Surprising Reserch Topic

Question:Explain include Directive and include Action of JSP



asked Sep 13, 2013 in JSP by anonymous
edited Sep 12, 2013
0 votes
28 views



Related Hot Questions

4 Answers

0 votes
fundamental concept like translation of JSP and difference between translation time and run time kind of concept
answered Sep 13, 2013 by anonymous
edited Sep 12, 2013
0 votes

 

Syntax for include Directive is <%@ include file="fileName" %> which means we are including some file to our JSP Page when we use include directive contents of included file will be added to calling JSP page at translation time means when the calling JSP is converted to servlet ,all the contents are added to that page .one important thing is that any JSP page is complied if we make any changes to that particular page but if we have changed the included file or JSP page the main calling JSP page will not execute again so the output will not be according to our expectation, this one is the main disadvantage of using the include directive that why it is mostly use to add static  resources, like Header and footer .
 
Syntax for include action is it’s a runtime procedure means the result of the JSP page which is mentioned in relative URL is appended  to calling JSP at runtime on their response object at the location where we have used this tag
So any changes made to included page is being effected every time, this is the main advantage of this action but only relative URL we can use here ,because request and response object is passed between calling JSP and included JSP.
answered Sep 13, 2013 by anonymous
edited Sep 12, 2013
0 votes
fundamental concept like translation of JSP and difference between translation time and run time kind of concept
answered Sep 13, 2013 by anonymous
edited Sep 12, 2013
0 votes

 

Syntax for include Directive is <%@ include file="fileName" %> which means we are including some file to our JSP Page when we use include directive contents of included file will be added to calling JSP page at translation time means when the calling JSP is converted to servlet ,all the contents are added to that page .one important thing is that any JSP page is complied if we make any changes to that particular page but if we have changed the included file or JSP page the main calling JSP page will not execute again so the output will not be according to our expectation, this one is the main disadvantage of using the include directive that why it is mostly use to add static  resources, like Header and footer .
 
Syntax for include action is it’s a runtime procedure means the result of the JSP page which is mentioned in relative URL is appended  to calling JSP at runtime on their response object at the location where we have used this tag
So any changes made to included page is being effected every time, this is the main advantage of this action but only relative URL we can use here ,because request and response object is passed between calling JSP and included JSP.
answered Sep 13, 2013 by anonymous
edited Sep 12, 2013

...