This simple tutorial gonna teach you how to install java 32-Bit or 64-Bit plugin in firefox.
Download java from the official website. http://java.com/en/download/ ->(Download tar.gz version)
You have both solution...32 and 64-Bit.
Choose one, or install both....and be bad boy
We first create the directory to place java there.

I assume you have downloaded java and placed in your root dir.

If 32-Bit Java!? Do this! BT 5 R3 x86
Code:
root@bt:~# pkill firefox 
root@bt:~# mkdir /opt/java/32/
root@bt:~# tar xvzf jre-7u17-linux-i586.tar.gz
root@bt:~# mv -f jre1.7.0_17/ /opt/java/32/
root@bt:~# update-alternatives --install /usr/bin/java java /opt/java/32/jre1.7.0_17/bin/java 1
root@bt:~# update-alternatives --set java /opt/java/32/jre1.7.0_17/bin/java
Adding the plugin to Firefox.
Code:
root@bt:~# ln -sf /opt/java/32/jre1.7.0_05/lib/i386/libnpjp2.so  /usr/lib/mozilla/plugins/
root@bt:~# export JAVA_HOME="/opt/java/32/jre1.7.0_17/bin/java"
32 Bit Java DONE!
-----------------------------------------------------------------------


If 64-Bit Java!? Then do this! BT 5 R3 x64
Code:
root@bt:~# mkdir /opt/java/64/
root@bt:~# tar xvzf jre-7u17-linux-x64.tar.gz
root@bt:~# mv -f jre1.7.0_17/ /opt/java/64/
root@bt:~# update-alternatives --install /usr/bin/java java /opt/java/64/jre1.7.0_15/bin/java 1
root@bt:~# update-alternatives --set java /opt/java/64/jre1.7.0_15/bin/java
Adding the plugin to Firefox.
Code:
root@bt:~# ln -sf /opt/java/64/jre1.7.0_17/lib/amd64/libnpjp2.so  /usr/lib64/mozilla/plugins/
root@bt:~# export JAVA_HOME="/opt/java/64/jre1.7.0_17/bin/java"
64 Bit Java DONE!
-------------------------------------------------------------------

Test it if works
root@bt:~# firefox http://java.com/en/download/testjava.jsp

---------------------------------------------------

Congrats!!! You Done it!