How to check JSP and Tomcat version?


You can easily check the JSP version. You need to create test.jsp page under your account and add the following code into that file and access the test.jsp page by using browser " http://domainname/test.jsp " then it shows the tomcat version, JSP version and servlet version.

<html><head><title>Test JSP page</title></head><body bgcolor=white>

<table border="0"><tr><td><h1>Sample Application JSP Page</h1>
This is the output of a JSP page that is part of the Hello, World application.
It displays several useful values from the requestwe are currently processing.</td></tr>

<table border="0" border="100%"><tr>
<th align="right">Request Method:</th>
<td align="left"><%= request.getMethod() %></td></tr><tr>
<th align="right">Servlet Path:</th>
<td align="left"><%= request.getServletPath() %></td></tr>

<th align="right">Working with server:</th>
<td align="left"><%= application.getServerInfo() %></td></tr>
<th align="right">Servlet Specification:</th>
<td align="left"><%= application.getMajorVersion() %>.<%= application.getMinorVersion() %></td></tr>
<th align="right">JSP version:</th>
<td align="left"><%= JspFactory.getDefaultFactory().getEngineInfo().getSpecificationVersion() %></td></tr>

  • Email, SSL
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How do I run servlet after servlet installation?

 To execute a servlet after servlet installation use, http://www.yourdomainname/servlets/

Which Tomcat JSP Version and Servlet Specifications is supported?

Apache Tomcat: 5.5.28Servlet Specification: 2.4JSP version: 2.0This information is subject to...

How do I test Java/JSP Servlets have been installed and are working fine?

To test Java/JSP Servlets have been installed and are working...

Where is WEB-INF folder? Where to upload .class and .jar files?

 WEB-INF folder is under public_html folder.The WEB-INF directory is divided into two...

What is JSP?

JSP is short of Java Server Pages. They are a mix of normal HTML with Java code embedded in them....