Another way (much more easier than the one I previously posted on May ’13) to install Java 7 under Ubuntu is presented below.
You don’t have to edit any files manually. Just type these commands in terminal with sudo:
sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install oracle-java7-installer
While upgrading your repositories, your Java will be up to date.