Two Laptop Bag
The moose likes JSP and the fly likes Init() & destroy() in jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Init() & destroy() in jsp" Watch "Init() & destroy() in jsp" New topic

Init() & destroy() in jsp

Dean Jones

Joined: Jun 18, 2002
Posts: 24
hi how it is possible to have the init(),destroy() functionality in a JSP PAge
Dave Vick
Ranch Hand

Joined: May 10, 2001
Posts: 3244
You need the jspInit() and jspDestroy() methods from the jspPage interface.

Anthony Villanueva
Ranch Hand

Joined: Mar 22, 2002
Posts: 1055
Yes just override the jspInit() and jspDestroy() methods using <%! %> tags to customize your JSP.
I agree. Here's the link:
subject: Init() & destroy() in jsp
It's not a secret anymore!