This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JSP and the fly likes Bad version number in .class file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Bad version number in .class file" Watch "Bad version number in .class file" New topic

Bad version number in .class file

sameer khazi

Joined: Sep 05, 2008
Posts: 28
Hi all..

Please let me know how to resolve the following error:

i am using jdk 1.6._10 , Tomcat 5.5 ; jstl 1.1.2

The error displayed by Tomcat 5.5 is ..

javax.servlet.ServletException: Bad version number in .class file

Thank you...
Ben Souther

Joined: Dec 11, 2004
Posts: 13410

It sounds like Tomcat is running under a different version of the JVM than what you used to compile your classes.

Tomcat's manager app (under Server Settings) will show you what JVM you're using.

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
Vinod K Singh
Ranch Hand

Joined: Sep 30, 2008
Posts: 198
This happens when a class compiled by higher version of Java is run under lower version of JVM.

My Blog
I agree. Here's the link:
subject: Bad version number in .class file
Similar Threads
HTTP Status 503 - This application is not currently available
Bad version number in .class file
do not understand compiling a servlet
HFSJ Jsp Compilation - Status 500 error message
Bad Version Number when deploying app