Common file which contains scriptlet code...

G

gautam.chavan

Hello all,

I have around 3 webpages which use the same scriptlet code.
Hence the code is repeated.
Can i put the common code in a file & include the file.
Similar to a *.js file where you can put your common javascript code.

regards,
Gatuam.
 
A

Aj-India

yes you can.
put the common code in a jsp page (for e.g., CommonCode.jsp ) and call
them with

<%@ include file="CommonCode.jsp"%>

in the other 3 pages.
Cheers,

Aj
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top