1.

Explain Jstl Catch Tag With An Example?

Answer»

JSTL catch tag: The JSTL catch tag is used to handle exception and doesn't forward the PAGE to the error page. For Example :

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<html>
<head>
<TITLE>Tag Example</title>
</head>
<body>
<c:catch>
<% int a = 0;
int B = 10;
int c = b/a;
%>
</c:catch>
</body>
</html>

JSTL catch tag: The JSTL catch tag is used to handle exception and doesn't forward the page to the error page. For Example :

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<html>
<head>
<title>Tag Example</title>
</head>
<body>
<c:catch>
<% int a = 0;
int b = 10;
int c = b/a;
%>
</c:catch>
</body>
</html>



Discussion

No Comment Found