Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Inhertance in jsp

 
lrk naidu
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all,
How can i get the properties from one jsp file to another Jsp.

The ex:like Class A
{
public void display()
}
class B extends A
{
//we get the properties from A
}


what is the similar type in jsp?
 
anupa oru
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
you can use something like
<%@ page extends="parentclassname"%>
Thanks
 
Jeroen Wenting
Ranch Hand
Posts: 5093
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But you shouldn't.
How often does it need to be repeated: do NOT use scriptlets in JSP.

For display code it's best to use some well designed dynamic includes.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic