Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #28593 > unrolled thread
| Started by | rdelaney2001@gmail.com |
|---|---|
| First post | 2015-09-01 15:34 -0700 |
| Last post | 2015-09-05 03:22 -0600 |
| Articles | 20 on this page of 21 — 13 participants |
Back to article view | Back to comp.lang.javascript
questions re Javascript rdelaney2001@gmail.com - 2015-09-01 15:34 -0700
Re: questions re Javascript mentificium@gmail.com - 2015-09-01 15:58 -0700
Re: questions re Javascript Tim Streater <timstreater@greenbee.net> - 2015-09-02 08:28 +0100
Re: questions re Javascript "Christoph M. Becker" <cmbecker69@arcor.de> - 2015-09-03 00:43 +0200
Re: questions re Javascript "Christoph M. Becker" <cmbecker69@arcor.de> - 2015-09-03 01:45 +0200
Re: questions re Javascript Arne Vajhøj <arne@vajhoej.dk> - 2015-09-03 19:57 -0400
Re: questions re Javascript "Christoph M. Becker" <cmbecker69@arcor.de> - 2015-09-04 02:37 +0200
Re: questions re Javascript Arne Vajhøj <arne@vajhoej.dk> - 2015-09-03 20:01 -0400
Re: questions re Javascript Martin Gregorie <martin@address-in-sig.invalid> - 2015-09-04 08:46 +0000
Re: questions re Javascript Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-09-05 09:35 +0200
Re: questions re Javascript Joshua Cranmer 🐧 <Pidgeot18@verizon.invalid> - 2015-09-04 10:09 -0500
Re: questions re Javascript Tim Streater <timstreater@greenbee.net> - 2015-09-04 16:37 +0100
Re: questions re Javascript Tim Streater <timstreater@greenbee.net> - 2015-09-04 22:51 +0100
Re: questions re Javascript Eternal Hope <laughingspam99@gmail.com> - 2015-09-05 20:29 +0100
Re: questions re Javascript "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2015-09-04 18:17 +0200
Re: questions re Javascript Arne Vajhøj <arne@vajhoej.dk> - 2015-09-04 19:40 -0400
Re: questions re Javascript Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-09-05 09:47 +0200
Re: questions re Javascript Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-09-05 22:16 +0200
Re: questions re Javascript Luuk <luuk@invalid.lan> - 2015-09-05 14:14 +0200
Re: questions re Javascript Jay Braun <lyngwyst@gmail.com> - 2015-09-02 14:42 -0700
Re: questions re Javascript Chuck Anderson <seemysig@thisis.invalid> - 2015-09-05 03:22 -0600
Page 1 of 2 [1] 2 Next page →
| From | rdelaney2001@gmail.com |
|---|---|
| Date | 2015-09-01 15:34 -0700 |
| Subject | questions re Javascript |
| Message-ID | <2b531f48-fff9-4c73-a116-22a3f110e919@googlegroups.com> |
I'm trying to get a handle in what Javascript is, isn't, what it does.... Is it a language, or a set of library routines? If the latter, how are they accessed? Is it used, or useful, for anything besides hovering the cursor over an image on a Web page? What is its relation to Java, as a plug-in? Are they independent? Does Javascript execute/reside 'inside' Java, so to speak? What are the limitations of the language, in terms of hardware, memory access, security, etc.? Thx, -- Rich
[toc] | [next] | [standalone]
| From | mentificium@gmail.com |
|---|---|
| Date | 2015-09-01 15:58 -0700 |
| Message-ID | <4028ba67-9c0f-46d9-b127-84f22e817499@googlegroups.com> |
| In reply to | #28593 |
On Tuesday, September 1, 2015 at 3:35:05 PM UTC-7, rdelan...@gmail.com wrote: > I'm trying to get a handle in what Javascript is, isn't, > what it does....[...] > > Is it used, or useful, for anything besides hovering > the cursor over an image on a Web page? [...] JavaScript serves Strong AI research: http://www.nlg-wiki.org/systems/Mind is a tutorial AI mind in English. http://www.nlg-wiki.org/systems/Dushka is the same JavaScript AI in Russian. http://ai.neocities.org/AiSteps.html provides more details on Strong AI. Cheers, Arthur T. Murray/Mentifex -- Major goal in life: Trigger a Technological Singularity; Minor goal: Overthrow the unelected government of China; Minor goal: Win a Nobel Prize in Physiology or Medicine; Minor goal: [X] Reunification of East and West Germany.
[toc] | [prev] | [next] | [standalone]
| From | Tim Streater <timstreater@greenbee.net> |
|---|---|
| Date | 2015-09-02 08:28 +0100 |
| Message-ID | <020920150828500988%timstreater@greenbee.net> |
| In reply to | #28593 |
In article <2b531f48-fff9-4c73-a116-22a3f110e919@googlegroups.com>, <rdelaney2001@gmail.com> wrote: >I'm trying to get a handle in what Javascript is, isn't, >what it does.... > >Is it a language, or a set of library routines? If >the latter, how are they accessed? Broadly speaking its a language that you can use to write scripts to manipulate the web page inside your browser. >Is it used, or useful, for anything besides hovering >the cursor over an image on a Web page? Eh? That sounds more like something you'd use CSS for. >What is its relation to Java, as a plug-in? Are they >independent? Does Javascript execute/reside 'inside' >Java, so to speak? Javascript has nothing to do with Java except for having a similar sounding name. >What are the limitations of the language, in terms of >hardware, memory access, security, etc.? Nothing to do with hardware, the language is interpreted by your browser. For the most part, you might be using it to create/remove/modify elements (such as tables, paragraphs, etc) that make up the web page being displayed. What is displayed would then change accordingly. -- "Please stop telling us what you feel. Please stop telling us what your intuition is. Your intuitive feelings are of no interest whatsoever, and nor are mine. I don't give a bugger what you feel, or what I feel. I want to know what the evidence shows." -- Richard Dawkins
[toc] | [prev] | [next] | [standalone]
| From | "Christoph M. Becker" <cmbecker69@arcor.de> |
|---|---|
| Date | 2015-09-03 00:43 +0200 |
| Message-ID | <ms7u1o$guu$1@solani.org> |
| In reply to | #28597 |
Stefan Ram wrote: > Tim Streater <timstreater@greenbee.net> writes: >> Javascript has nothing to do with Java except for having a similar >> sounding name. > > There are so many similiarities between the two languages, > that I can't name them all. For example, in both Java and > JavaScript, > > 2 + "x" > > gives »"2x"«, Does that really work in Java? Most certainly the following won't: int x = 2; String y = "x"; x + y; > while in many other languages it does not. > In both Java and JavaScript, the modulo operator »%« can be > used for doubles, Well, JavaScript has only "doubles" (actually, Numbers), but no integers (I'm deliberately ignoring asm.js), so there's no point in defining an modulo operator that wouldn't work with "doubles". > while in many other languages, it cannot. > Both have »instanceof« with a similar meaning, while other > languages do not. Counter-examples: C#, PHP. > In both languages »x == x« is false, when > x is NaN. What is enforced by IEEE 754. > And there are so many more similarities. And this > is no surprise, as Brendan Eich, the creator of JavaScript, > tells us: > > »The diktat from upper engineering management was that > the language must "look like Java".« > > I have read this sentence »Javascript has nothing to do with > Java except for having a similar sounding name« so often. > One copies it from the other. But not one stops to think! > Or to read. If one knows just a little bit about Java and > JavaScript, it is obvious that they have so much in common. Of course, JavaScript and Java have much in common. Mostly, that JavaScript's syntax was designed to resembles Java's, even though early versions of JavaScript and Java were *very* different. Early versions of Java didn't even have closures (a basic building block of all but the most trivial JavaScript scripts), and JavaScript doesn't have classes until recently (and AFAIK these "classes" are still only a thin wrapper over the more versatile prototypal inheritance). Comparing JavaScript with Java is like comparing apples with oranges (yes, both have a lot of similarities…). I consider somewhat recent versions of PHP to be more similar to Java than JavaScript is, for instance. -- Christoph M. Becker
[toc] | [prev] | [next] | [standalone]
| From | "Christoph M. Becker" <cmbecker69@arcor.de> |
|---|---|
| Date | 2015-09-03 01:45 +0200 |
| Message-ID | <ms81n8$tlh$1@solani.org> |
| In reply to | #28604 |
Stefan Ram wrote:
> "Christoph M. Becker" <cmbecker69@arcor.de> writes:
>> Does that really work in Java? Most certainly the following won't:
>> int x = 2;
>> String y = "x";
>> x + y;
>
> Not exactly in this wording, but essentially:
>
> public final class Main
> { public static void main( final java.lang.String[] args )
> { final int x = 2;
> final java.lang.String y = "x";
> java.lang.System.out.println( x + y ); }} /* prints:
> 2x */
Interesting, thanks! Nonetheless this seems to be rather a particular
convenience regarding "constants", and not a general flexibility of the
type system.
>> versions of JavaScript and Java were *very* different. Early versions
>> of Java didn't even have closures (a basic building block of all but the
>
> One must not confuse the syntactic feature of function literals
> (called »lambdas«) with the semantic feature of entities that
> »close over« (contain) local environments (called »closures«).
Thanks for the clarification.
> (Possibly, the first versions of LISP had lambdas, but not
> closures, too, then closures were invented to solve the
> »outward funarg problem« IIRC.)
IIRC, early versions of LISP where dynamically scoped (a concept I still
can't really grasp, and what unfortunately is reflected by `this` in
ECMAScript), whereas only later versions (most notably Common Lisp and
Scheme) defaulted to lexical scoping (which is much more intuitive to me).
Anyhow, I still think that Java has its main roots in C++, and
JavaScript in Scheme, and as such I'd categorize Java as
object-oriented, but JavaScript as functional (actually, applicative)
programming language (the lines are blurred, and are becomming more
blurred as time goes by, though).
PS: I'm aware of Guy L. Steele's influence on Scheme, Common Lisp *and*
Java.
--
Christoph M. Becker
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2015-09-03 19:57 -0400 |
| Message-ID | <msamoq$9s$1@speranza.aioe.org> |
| In reply to | #28604 |
On 9/2/2015 6:43 PM, Christoph M. Becker wrote: > Stefan Ram wrote: >> Both have »instanceof« with a similar meaning, while other >> languages do not. > > Counter-examples: C#, PHP. It is not called instanceof in C#. Arne
[toc] | [prev] | [next] | [standalone]
| From | "Christoph M. Becker" <cmbecker69@arcor.de> |
|---|---|
| Date | 2015-09-04 02:37 +0200 |
| Message-ID | <msap4a$reh$1@solani.org> |
| In reply to | #28621 |
Arne Vajhøj wrote: > On 9/2/2015 6:43 PM, Christoph M. Becker wrote: >> Stefan Ram wrote: >>> Both have »instanceof« with a similar meaning, while other >>> languages do not. >> >> Counter-examples: C#, PHP. > > It is not called instanceof in C#. Oops – I've googled not thoroughly enough. Thanks for the correction. -- Christoph M. Becker
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2015-09-03 20:01 -0400 |
| Message-ID | <msan0e$19l$1@speranza.aioe.org> |
| In reply to | #28597 |
On 9/2/2015 7:20 AM, Stefan Ram wrote: > Tim Streater <timstreater@greenbee.net> writes: >> Javascript has nothing to do with Java except for having a similar >> sounding name. > > There are so many similiarities between the two languages, > that I can't name them all. For example, in both Java and > JavaScript, > > 2 + "x" > > gives »"2x"«, while in many other languages it does not. > In both Java and JavaScript, the modulo operator »%« can be > used for doubles, while in many other languages, it cannot. > Both have »instanceof« with a similar meaning, while other > languages do not. In both languages »x == x« is false, when > x is NaN. If these are the criteria then a lot of languages are like Java. > And today, JavaScript is part of Java (the JRE), so it is > actually wrapped together with Java, and today JavaScript > can finally be used /to script Java/ out of the box. I don't think that Java being able to execute JavaScript tell much about whether the two languages are close. I can not see any reason why you could not embed a JavaScript engine in COBOL runtime. > The > promise of its name is thus fulfilled. And both come from > the same company that also owns the trademark for both names. No. SUN created Java. NetScape created JavaScript. NetSCape got permission from SUN to use the Java prefix. Arne
[toc] | [prev] | [next] | [standalone]
| From | Martin Gregorie <martin@address-in-sig.invalid> |
|---|---|
| Date | 2015-09-04 08:46 +0000 |
| Message-ID | <msblp8$hgg$3@dont-email.me> |
| In reply to | #28622 |
On Thu, 03 Sep 2015 20:01:16 -0400, Arne Vajhøj wrote: > I can not see any reason why you could not embed a JavaScript engine in > COBOL runtime. > ...or run both a COBOL compiler and the generated code in the JRE. -- martin@ | Martin Gregorie gregorie. | Essex, UK org |
[toc] | [prev] | [next] | [standalone]
| From | Thomas 'PointedEars' Lahn <PointedEars@web.de> |
|---|---|
| Date | 2015-09-05 09:35 +0200 |
| Message-ID | <1455138.2aFc8b5frt@PointedEars.de> |
| In reply to | #28622 |
[F'up2 comp.lang.javascript] Arne Vajhøj wrote in <news:comp.lang.javascript> and <news:comp.lang.java.programmer>: > On 9/2/2015 7:20 AM, Stefan Ram wrote: >> The >> promise of its name is thus fulfilled. And both come from >> the same company that also owns the trademark for both names. > > No. > > SUN created Java. _Sun_ > NetScape created JavaScript. > > NetSCape got permission from SUN to use the Java prefix. _Netscape_ Speakers of German (and hopefully, in the future, speakers of English as well, as efforts at translation into English are underway) may want to read my 2012 thesis on the subject, and follow the references therein, to clarify some of their misconceptions. It is referred to from the ECMAScript [Support] Matrix (see signature), which since then serves as the proof of concept of the thesis. -- PointedEars FAQ: <http://PointedEars.de/faq> | SVN: <http://PointedEars.de/wsvn/> Twitter: @PointedEars2 | ES Matrix: <http://PointedEars.de/es-matrix> Please do not cc me. / Bitte keine Kopien per E-Mail.
[toc] | [prev] | [next] | [standalone]
| From | Joshua Cranmer 🐧 <Pidgeot18@verizon.invalid> |
|---|---|
| Date | 2015-09-04 10:09 -0500 |
| Message-ID | <mscc3f$apc$1@dont-email.me> |
| In reply to | #28597 |
On 9/2/2015 6:20 AM, Stefan Ram wrote: > There are so many similiarities between the two languages, > that I can't name them all. Really? I can: * Java and JS share the same core C-ish syntax (but not necessarily semantics) for expressions and statements. * They both use a strictly-defined evaluation order instead of C's undefined evaluation order. * A few method names (e.g., toString, or Math.sin) are the same. * The JS Date object is explicitly modelled on Java's Date object (unfortunately). * Their names start with the same first four letters. That's really about it. Java and JS use hugely different internal representations, and the semantics are often vastly different. Most notably, JS has no integers, only IEEE754 doubles, and the == operator in Java corresponds to === in JS where == in JS is .equals() in Java. For my part, calling the languages similar when semantics are so different does a disservice to neophytes attempting to learn one or the other. It's like saying English and French are similar, because they share the same grammatical constructs and many words are cognates. Peut-être il est vrai, mais on ne peut pas converser avec un autre sans apprendre à parler l'autre langue. -- Beware of bugs in the above code; I have only proved it correct, not tried it. -- Donald E. Knuth
[toc] | [prev] | [next] | [standalone]
| From | Tim Streater <timstreater@greenbee.net> |
|---|---|
| Date | 2015-09-04 16:37 +0100 |
| Message-ID | <040920151637554925%timstreater@greenbee.net> |
| In reply to | #28629 |
In article <to-do-20150904163124@ram.dialup.fu-berlin.de>, Stefan Ram <ram@zedat.fu-berlin.de> wrote: >=?UTF-8?Q?Joshua_Cranmer_=f0=9f=90=a7?= <Pidgeot18@verizon.invalid> writes: >>other. It's like saying English and French are similar, because they >>share the same grammatical constructs and many words are cognates. > > What I objected to was the typical wording > > »JavaScript /has nothing to do/ with Java.«. > > To me, it would be disputable too when one would say, > > »English has nothing to do with French.«. > > Also, it depends on the point of view. Compared with a > language like »Archi«, which has 1.5 million forms of verb > endings and more than 150 phonemes, English and French > suddenly appear to be more similar. Given that the OP didn't seem to know very much, at this point in his learning process it is *much* *better* to say that these languages are not related. Then he can get on. He can learn a more nuanced lesson later on. All you and similar posters are likely to do at this stage, with your pedantry, is to confuse him. -- "Once you adopt the unix paradigm, the variants cease to be a problem - you bitch, of course, but that's because bitching is fun, unlike M$ OS's, where bitching is required to keep your head from exploding." - S Stremler in afc
[toc] | [prev] | [next] | [standalone]
| From | Tim Streater <timstreater@greenbee.net> |
|---|---|
| Date | 2015-09-04 22:51 +0100 |
| Message-ID | <040920152251414544%timstreater@greenbee.net> |
| In reply to | #28631 |
In article <Java-and-JavaScript-20150904164419@ram.dialup.fu-berlin.de>, Stefan Ram <ram@zedat.fu-berlin.de> wrote: >Tim Streater <timstreater@greenbee.net> writes: >>Given that the OP didn't seem to know very much, at this point in his >>learning process it is *much* *better* to say that these languages are >>not related. Then he can get on. He can learn a more nuanced lesson >>later on. All you and similar posters are likely to do at this stage, >>with your pedantry, is to confuse him. > > You might underestimate the intelligence of a beginner > when you believe that the correct answer > > »JavaScript and Java are different languages.« > > will significantly confuse him. You didn't say they were different languages. If you had, all would have been well. Instead you went off into a pedantic labyrinth where the learner doesn't need to go. It has nothing to do with the learner's intelligence and everything to do with interpreting his question and giving a useful answer. -- "... you must remember that if you're trying to propagate a creed of poverty, gentleness and tolerance, you need a very rich, powerful, authoritarian organisation to do it." - Vice-Pope Eric
[toc] | [prev] | [next] | [standalone]
| From | Eternal Hope <laughingspam99@gmail.com> |
|---|---|
| Date | 2015-09-05 20:29 +0100 |
| Message-ID | <msffmh$5qo$1@dont-email.me> |
| In reply to | #28635 |
On 04/09/2015 22:51, Tim Streater wrote: > In article > <Java-and-JavaScript-20150904164419@ram.dialup.fu-berlin.de>, Stefan > Ram <ram@zedat.fu-berlin.de> wrote: > >> Tim Streater <timstreater@greenbee.net> writes: >>> Given that the OP didn't seem to know very much, at this point in his >>> learning process it is *much* *better* to say that these languages are >>> not related. Then he can get on. He can learn a more nuanced lesson >>> later on. All you and similar posters are likely to do at this stage, >>> with your pedantry, is to confuse him. >> >> You might underestimate the intelligence of a beginner >> when you believe that the correct answer >> >> »JavaScript and Java are different languages.« >> >> will significantly confuse him. > > You didn't say they were different languages. If you had, all would > have been well. Instead you went off into a pedantic labyrinth where > the learner doesn't need to go. > > It has nothing to do with the learner's intelligence and everything to > do with interpreting his question and giving a useful answer. Sanity. Alive and well in c.l.j.p. Good to see -- Laughing Spam Fritter
[toc] | [prev] | [next] | [standalone]
| From | "Evertjan." <exxjxw.hannivoort@inter.nl.net> |
|---|---|
| Date | 2015-09-04 18:17 +0200 |
| Message-ID | <XnsA50BBA0F890CBeejj99@194.109.6.166> |
| In reply to | #28629 |
ram@zedat.fu-berlin.de (Stefan Ram) wrote on 04 Sep 2015 in comp.lang.javascript: > What I objected to was the typical wording > > ŻJavaScript /has nothing to do/ with Java.Ž. It has NOTHING TO DO with it. That MEANS: that the word "Java" in "Javascript" does not mean it is the scripting [=interpreting] form of the compiler-language "Java", and cannot be compared with Vbscript as the scripting form of Visual Basic, ot other script forms of compiler lenguages, or perhaps other compiler forms of scripting languages. It does NOT mean that: both are not computer-languages, both are not a subset of English words, both have never influenced each other, both are nowhere influenced by any common earlier language, are both used by human beings, some of them being smarter than others. -- Evertjan. The Netherlands. (Please change the x'es to dots in my emailaddress)
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2015-09-04 19:40 -0400 |
| Message-ID | <msda5l$agg$1@speranza.aioe.org> |
| In reply to | #28629 |
On 9/4/2015 11:33 AM, Stefan Ram wrote: > =?UTF-8?Q?Joshua_Cranmer_=f0=9f=90=a7?= <Pidgeot18@verizon.invalid> writes: >> other. It's like saying English and French are similar, because they >> share the same grammatical constructs and many words are cognates. > > What I objected to was the typical wording > > »JavaScript /has nothing to do/ with Java.«. > > To me, it would be disputable too when one would say, > > »English has nothing to do with French.«. I think the term "has nothing to do with" should be seen in context. If it is a thread about the evolution of languages and how they relate, then it is not a good statement. If it is a thread with a specific question about syntax/semantics/library, then I think it is a pretty good statement. Any attempt to answer a Java question based on JavaScript or a JavaScript question based on Java is very bad, because the risk of the answer being wrong is huge. And it is actually the same about English and French. If one is discussing history then certainly French influenced English after 1066 and in modern times English has probably influenced French a little bit as well (even though they try hard to create French equivalent words). But if it is a question about grammar rules and pronunciation, then it would most likely result in incorrect answers to try and answer question for one based on the other. Arne
[toc] | [prev] | [next] | [standalone]
| From | Thomas 'PointedEars' Lahn <PointedEars@web.de> |
|---|---|
| Date | 2015-09-05 09:47 +0200 |
| Message-ID | <3247094.1kJgyrEJG5@PointedEars.de> |
| In reply to | #28637 |
[F'up2 comp.lang.javascript] Arne Vajhøj wrote: > On 9/4/2015 11:33 AM, Stefan Ram wrote: >> What I objected to was the typical wording >> >> »JavaScript /has nothing to do/ with Java.«. >> >> To me, it would be disputable too when one would say, >> >> »English has nothing to do with French.«. > > I think the term "has nothing to do with" should be seen in context. > > If it is a thread about the evolution of languages and how they > relate, then it is not a good statement. > > If it is a thread with a specific question about > syntax/semantics/library, then I think it is a pretty good > statement. The statement should be modified to say “has *little* to do with Java” in that context because JavaScript was intentionally designed to resemble Java syntactically and semantically. Please stop crossposting without Followup-To. A discussion belongs only into to *one* newsgroup; in this case, comp.lang.javascript. -- PointedEars FAQ: <http://PointedEars.de/faq> | SVN: <http://PointedEars.de/wsvn/> Twitter: @PointedEars2 | ES Matrix: <http://PointedEars.de/es-matrix> Please do not cc me. / Bitte keine Kopien per E-Mail.
[toc] | [prev] | [next] | [standalone]
| From | Thomas 'PointedEars' Lahn <PointedEars@web.de> |
|---|---|
| Date | 2015-09-05 22:16 +0200 |
| Message-ID | <1956488.2vupmE4M81@PointedEars.de> |
| In reply to | #28640 |
[F'up2 comp.lang.javascript] Thomas 'PointedEars' Lahn wrote: > Arne Vajhøj wrote: >> On 9/4/2015 11:33 AM, Stefan Ram wrote: >>> What I objected to was the typical wording >>> >>> »JavaScript /has nothing to do/ with Java.«. >>> >>> To me, it would be disputable too when one would say, >>> >>> »English has nothing to do with French.«. >> >> I think the term "has nothing to do with" should be seen in context. >> >> If it is a thread about the evolution of languages and how they >> relate, then it is not a good statement. >> >> If it is a thread with a specific question about >> syntax/semantics/library, then I think it is a pretty good >> statement. > > The statement should be modified to say “has *little* to do with Java” in > that context because JavaScript was intentionally designed to resemble > Java syntactically and semantically. And, I should add, probably as a result of the Sun/Netscape agreement, starting from version 1.2 (in Netscape 4.0), (Netscape) JavaScript was modified to access Java applets (a feature called LiveConnect, actually a part of the Netscape AOM, which was removed from the core language definition with version 1.4 (server-side only) and eventually became XPConnect, an official part of the Mozilla AOM, with Mozilla JavaScript 1.5/Mozilla 1.0; the origin of the Netscape Plugin API [NPAPI] for which support is gradually being removed from browsers now), and Java was modified so that you could access JavaScript code from applets embedded in an HTML document (still called LiveConnect). <https://en.wikipedia.org/wiki/NPAPI> p. -- PointedEars FAQ: <http://PointedEars.de/faq> | SVN: <http://PointedEars.de/wsvn/> Twitter: @PointedEars2 | ES Matrix: <http://PointedEars.de/es-matrix> Please do not cc me. / Bitte keine Kopien per E-Mail.
[toc] | [prev] | [next] | [standalone]
| From | Luuk <luuk@invalid.lan> |
|---|---|
| Date | 2015-09-05 14:14 +0200 |
| Message-ID | <55EADCBF.9070005@invalid.lan> |
| In reply to | #28597 |
On 02-09-15 13:13, Stefan Ram wrote: > Newsgroups: comp.lang.javascript,comp.lang.java > > Tim Streater <timstreater@greenbee.net> writes: >> Javascript has nothing to do with Java except for having a similar >> sounding name. > > There are so many similiarities between the two languages, > that I can't name them all. For example, in both Java and > JavaScript, > They (Java & Javascript) might be similar, but they have noting to do with each other. Javascript is a language based on a standard (https://en.wikipedia.org/wiki/ECMAScript) Java is owned by Oracle (so, not based on an independant standard, besides the standard that Oracle creates for it.....)
[toc] | [prev] | [next] | [standalone]
| From | Jay Braun <lyngwyst@gmail.com> |
|---|---|
| Date | 2015-09-02 14:42 -0700 |
| Message-ID | <c1a99391-375e-47bc-97e0-d20ceff5b9bb@googlegroups.com> |
| In reply to | #28593 |
> Is it a language, or a set of library routines? If > the latter, how are they accessed? It is a language designed to run in a web browser. It adds dynamic behaviors that static HTML pages cannot perform. > Is it used, or useful, for anything besides hovering > the cursor over an image on a Web page? A little Googling will convince you that is is. > What is its relation to Java, as a plug-in? Are they > independent? Does Javascript execute/reside 'inside' > Java, so to speak? JavaScript was originally called Mocha, then LiveScript by its inventors at NetScape. The name JavaScript was intended to take advantage of Java's growing popularity in the mid-to-late 1990s. While the two share some syntactic heritage from C, they are independent languages designed for distinct purposes. Java programs execute in the JRE/JVM, while JavaScript generally runs in a browser. There are some "server-side" platforms for running JavaScript, such as Node.js, as well as a version of JavaScript that runs in the JRE, called Rhino. But JavaScript is *not* a subset of variant of Java. There is also something called BeanShell, which is essentially scripted Java that can run inside the JRE, even as part od a Java application, but it has nothing to do with JavaScript. (I mention it because the name JavaScript would have been an ideal name for BeanShell, but it was already taken.) > What are the limitations of the language, in terms of > hardware, memory access, security, etc.? Think of it as a programming language whose platform is the browser. So, while it is expressive and powerful, you cannot access your operating system's file system, TCP ports, and other resources outside the browser.
[toc] | [prev] | [next] | [standalone]
Page 1 of 2 [1] 2 Next page →
Back to top | Article view | comp.lang.javascript
csiph-web