For a web interface I would recommend markup (HTML). After all that's search engine friendly. For trailing mouse gadgets or presenting ads you use JS or DHTML. For other things it's becoming multiple choice.
Not everyone has the Java run-time engine installed. Also it takes a while to load for the first page with Java.
A server application typically uses PHP or Perl (if we are talking web-aps) which gets translated to html by the server before reaching the user.
I mainly use VB and Lisp (Yeah, still excists) for the aps I wrote, but these weren't designed to use on the web.
I'm still pretty much confused here. Not knowing what it is you want to learn from this.
Comparing the two is like comparing blue widgets with orange widgets. And I actually think you would like the brown ones (very rare widgets that is).
As far as I know (and that isn't that much on this subject) Java was developed by SUN as an platform independent programming language and the code needs to be compiled. JS was developed by Netscape and is an interpreted language (by your browser).
You use JS for displaying ads on your webpage, gadgets (like mouse trails). You use Java for whatever it is you want to use Java (can be games as an example).
Maybe what you want to hear is that JS is within your HTML code as part of the webpage. And Java would be a stand-alone application (allthough it can be rendered within the page).