We generally create methods in a java class, import them into a jsp file and call those methods in our jsp files.
But we are working in a client environment, we do not have access to create or modify .java files. So we desperately need to create a function in a jsp file and call it from another jsp file.
For example:
A.jsp
.....
<jsp:include page="B.jsp"/>
....
<%= getName(); %>
B.jsp ....
<%!
public String getName()
{
return "Hello";
}
>%
Is there any way to do this?.