Why Javascript is called Javascript (there is no relation between Java and Javascript) why its not called HTMLScript or XMLScript. Any historical reason for this?
The language has similarities to C-adjecents to which Java counts aswell.
It was first named Mocha but later renamed to LiveScript and finally to JavaScript due to marketing reasons. To accomodate the Java trend during that time there was an interface between LiveScript and Java called LiveConnect. This connection was intented to be expressed with the new name "JavaScript".
It's just a historical mistake. (and according to me there's no real valid reason to name JavaScript as JavaScript)
They have similar names because market was crazy about these new technologies when they were starting to come out (actually Netscape was about to include Java inside Netscape) and they accidentally chose to change LiveScript name to JavaScript. I wrote accidentally because they have nothing in common (apart from being two programming languages) so there's no a real, analytic reason for this similarity.
JavaScript, was originally named Mocha, later it was renamed to LiveScript, and then to JavaScript.
The LiveScript to JavaScript name change came because Netscape and Sun did a license agreement.
The language was then submitted for standarization to the ECMA International Organization, by that time, Netscape didn't allowed the use of the "JavaScript" name, so the standarized language is named ECMAScript.
JavaScript isn’t actually an open name. Now it's a trademark of Sun (now Oracle).
There still a lot of confusion, some people still think that JavaScript, JScript, and ECMAScript are three different languages.
ECMAScript is the "standards" name for the language.
JavaScript is technically a "dialect" of ECMAScript, the Mozilla Foundation can use "JavaScript" as the name of their implementations (currently present on the Rhino and SpiderMonkey engines).
In the early days, Microsoft decided also to do what Netscape was doing on their own browser, and they developed JScript, which is also an ECMAScript dialect, but was named in this way to avoid trademark issues.
At the time Javascript or Livescript was launched into market the Sun MicroSystems was busy with the java creation so they named it as javascript. Also it uses some basic construts of the java.
Maybe this would help? http://en.wikipedia.org/wiki/JavaScript#History