java not working on Lion
Unlike previous OS X iterations, Java does not come installed by default on Lion OS X. Instead, you need to download it and enable it.
First, check to see whether Java is installed by running this command in Terminal.app
If you don’t get a version number back, then you need to go here first and download the Java update from Apple: http://support.apple.com/kb/DL1515
Once Java is installed, then you need to enable it. In your Applications > Utilities folder, you should find the Java Preferences.app. Double click on that, and in the ‘General’ tab, click the enable checkbox at the top (see screenshot above).