Beta
×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

JavaScript Inventor Speaks Out

samzenpus posted more than 9 years ago | from the listen-up dept.

Mozilla 267

Anonymous Coward writes "Brendan, on his mozillazine blog talks about JavaScript 1, 2, and in between in light of DHTML and AJAX. In an informal blog entry he answers frequently asked questions such as fixing Unicode in regular expressions, multi-threading, weak numeric typing, and obfuscating code."

cancel ×

267 comments

Sorry! There are no comments related to the filter you selected.

JavaSuck? (-1, Flamebait)

Anonymous Coward | more than 9 years ago | (#12829091)

Why not use ASP? Or .Net? Open source my ass...

Oh yeah, FP.

Re:JavaSuck? (-1, Troll)

Battery Powered (872120) | more than 9 years ago | (#12829111)

I think the more important question is this: how do we know that this guy really invented javascript? Any freak with an interent connection can post on a blog that they invented anything they want, after all.

Hell, Dan Quayle didn't even need a blog, and he claimed to have invented the internet!

Re:JavaSuck? (2, Informative)

Jedbro (27646) | more than 9 years ago | (#12829347)

Maybe because we actually know what we are talking about.

Brendan Eich worked at Netscape back when the web was pioneered.. he created Javascript while there, and wrote the entire javascript engine for the Netscape browser (version 2 or 3, can't remember).. facts are facts.. I'm sure theres more info at wikipedia.

Re:JavaSuck? (0)

Anonymous Coward | more than 9 years ago | (#12829277)

JScript.NET comes in the box, you know.

fr1st ps0t!! (-1, Offtopic)

rudy_wayne (414635) | more than 9 years ago | (#12829092)

fr1st ps0t!!

Re:fr1st ps0t!! (1)

Monkeman (827301) | more than 9 years ago | (#12829152)

Or not. (Who attempts FP without anonymous anyway?)

Your sig got a chuckle from me though.

4th POST (-1, Offtopic)

Anonymous Coward | more than 9 years ago | (#12829109)

HAHAHA I R cool.

Just what I wanted! (-1, Troll)

Anonymous Coward | more than 9 years ago | (#12829121)

Multi-threaded popup windows. Or not.

I'd rather use a browser configured to show me the world wide web as a bunch of hypertext documents, not as a bloated adware-infested and spyware-infested application that moves crap around inside the browser window and pops up windows.

Re:Just what I wanted! (4, Funny)

Mr. Cancelled (572486) | more than 9 years ago | (#12829247)

I'd rather use a browser configured to show me the world wide web as a bunch of hypertext documents, not as a bloated adware-infested and spyware-infested application that moves crap around inside the browser window and pops up windows.

Yes, but this is a discussion about JavaScript, not Flash.

Re:Just what I wanted! (-1, Offtopic)

Anonymous Coward | more than 9 years ago | (#12829357)

adolf hitroll anal cocks anonymous cowrad anonymous pancake bank of ame rica atm big ass spork bigdogscock carp flounderson cheezydee clit cmde rtaco cmdr shithead cyborg monkey diaper tales donkeyhote drunked cowar d egg troll elcagado fecal troll matter forged forsh freshpondphil fuc ky the troll genghis troll handybundler hettb iagreewiththispost j0nkat z klerck l0rdkariya limpdawg mao zedong metrollica mighty-troll mmmmm mmmmmmmmmmmmmm neal n bob on by pr0n king profane motherfucker ralph je whater nader recipetroll returnofthe spork ringbarer robotroll rock 'n' troll script kiddie l33t serial troller sexual asspussy subject line tr oll tasty beef jerky the anime troll the lyrics guy the messenger the t urd report the wipo troll things to do today trollaxor trollercoaster tr olltime whistler's mother yourmissionfortoday yr0 and all the AC's and p eople I forgot to include. and now a word from our sponser: It has come to my attention that the entire Linux community is a hotbed of so called 'alter native sexuality,' which includes anything from hedonistic orgies to homosex uality to pedophilia. What better way of demonstrating this than by looking at the hidden messages contained within the names of some of Linux's most o utspoken advocates: * Linus Torvalds [microsoft.com] is an anagram of s lit anus or VD 'L,' clearly referring to himself by the first initial. * Richard M. Stallman [geocities.com], spokespervert for the Gaysex's Not Unus ual 'movement' is a n anagram of mans cram thrill ad. * Alan Cox [mi c rosoft.com] is barely an anagram of anal c ox which is ju st so filthy and u n christian it unnerves me.I' m sure that E ric S. Raymond, composer o f the satanic homosexual [goatse.cx ] propaganda diatribe The Cathe dral and the Bizarre, is proba bly an anagram of something queer, but we don't need to look th at far as we know h e 's always shoving a g un up some poor little boy's rectum. Update: Eric S. Raymond is actual ly an anagram for secondary rim and cord in my a rse. It just goes to sho w you that he is indeed queer.Upda te the Second: It is also documented that Evil Sicko Gaymond is responsibl e for a nauseating piece of code called Fetchmai l [microsoft. co m], which is ob viously sinister sodomi te slang for 'Felch Male' -- a disgusting practise. For those not in the know, 'felching' is the act performed by two perverts wherein one sucks their own post-coital ejaculate out of the other's rectum. In fact, it appears that the dirty Linux faggots set out to undermine the good Repub lican institution of e-mail, turning it into 'e-male.' As far as Richar d 'Master' Stallman goes, that filthy fudge-packer was actually quo ted [salon.com] on leftist commie propaganda site Salon.com as saying the foll o wing: 'I've been resistant to the pressu re to conform in any circumstance, ' he says. 'It's about b eing able to question conventional wisdom,' he asserts. 'I be lieve in lov e, but not monogamy,' he says plainly.An d this isn't a made up troll bullshit either! He actually sta ted this tripe, which makes it obvious that he is trying to politely say that he's a flaming homo [comp-u-geek.net] slut [rotten.com]! Speaking about 'flaming,' who better to point out a s a filthy chutney ferret than Slashdot's very own self-confessed pedera st Jon Katz. Although an obvious deviant anagram cannot be found from hi s name, he has already confessed, nay boasted of the homosexual [goatse. cx] perversion of corrupting the innocence of young children [slashdot.o rg]. To quote from the article linked: 'I've got a rare kidney disease, ' I told her. 'I have to go to the bathroom a lot. You can come with m e if you want, but it takes a while. Is that okay with you? Do you w ant a note fro m my docto r? ' Is this why you wer e touching your penis [rotten.co m] in the cinema, Jon? An d letting the other boys touch it too? We s hould also point o ut that Jon Katz refers to hims elf as 'Slashdot's resident Gasbag.' Is there any more doubt ? For those fortunat e few who aren't aware of the list of homosexual [goatse.cx ] terminolog y found inside the Linux 'Sauce Code,' a 'Gasbag' is a pervert who gains sexual grati fication from having a t hin straw inserted into his urethra (o r to use the common parlanc e, 'piss-pip e'), then his homo s exual [goatse.cx]lover blow s firmly do wn the st ra w to inflate his scrotum. This is, of course , w hen he's not busy violating the d ignity and copyright o f posters to Slashdot by gathering to gether their postings and publishing them en masse to further his twiste d and manipu lative journalistic agenda. Sick, disgusting antichristian perverts, the lot of t hem. In addition, many of the Linux distr ibutions (a 'distrib ution' is the most common way to spread the faggots ' war e s) are run by faggot groups. The Slack ware [redha t.com ] distro is named after the 'Slack-wea r' fags wear to a llow easy access to the anus for sexu al purposes. Fur thermore, Slackware is a close anagr am of claw a rse , a reference to the homosexual [goa tse.cx] prac ti ce of anal fisting. The Mandrake [s lackware.com] pr oduct is run by a group of French f aggot satanists, and i s n amed after the faggot nickname for the vibrator. It was also cho sen because it is an anagram for d ark amen and ram naked, w h ich is what they do. Another 'dis tro,' (abbrieviated a s s uch because it sounds a bit like 'Disco,' which is wher e h o mosexuals [goatse.cx] preyed on y oung boys in the 1970s), is Debi an, [mandrake.com] an anagram of in a bed, which could be conside red innocent enough (after all, a bed is both where we sleep and p ray), until we realise what othe r names Debian uses to descri be their foul wares. 'Woody' is obvi ous enough, being a term for t h e erect male penis [rotten.com], glistening with pre- cum. But far sicker is the phrase 'Frozen Potato' that they use . T his f ilthy term, again found in the s ecret homosexual [goats e.cx] 'Sa uce Code,' refers to the solo ho mosexual [goatse.cx] practice of d efecating into a clear polythen e bag, shaping the turd into a cru de approximation of the male p hallus, then leaving it in the fre ezer overnight until it become s solid. The practitioner then proc eeds to push the frozen 'pota to' up his own rectum, squeezing it in and out until his tight y oung balls erupt in a screaming or gasm. And Red Hat [debian.o rg] is secret homo [comp-u-geek.n e t] slang for the tip of a p enis [rotten.com ] that is soaked i n blood from a freshly vio lated underage ringpiece. The fag s h ave even invented specia l tools to aid their faggotry! For e xample, the 'supermount' t ool was devised to allow deeper pene t ration, which is good for fags because it gives more pressure o n the prostate gland. 'Au tomount' is used, on the other hand, b ecause Linux users are a ll fat and gay, and need to mount each other [comp-u-geek.net] automaticall y. The depths of their depravity can be seen in their use of 'mount points.' These a re, plainly speaking, th e different poin ts of penetration. T he main one is obviousl y /anus, but there are others. Milit ant fags even say 'ther e is no /opt mount point' because fo r these dirty perverts faggotry is not optional but a way of life. More evidence is in the fact that Linux users say how m uch they love `man`, e ven going so far as to say that all new L inux users (who are in fact just innocent heterosexuals indoc tr inated by the gay prop aganda) should try out `man`. In no o th er syste m do users boast of their frequent recourse to a man. Other ar eas of the system also show Linux's inherit gayness. For example, pe o ple are often told of the 'FAQ,' but how many innocent heterosexual Wi ndows [amiga.com] use rs know what this actually means. The answer is shocking: Faggot Anal Qu est: the voyage of discovery for newly converted fags! Even the title ' Slashdot [geekizoid.com]' originall y referred to a homosexual [goatse. cx] practice. Slashdot [kuro5hin. o rg] of course refers to the popular gay practice of blood-letting . The Slashbots, o f course are th ose super-zealous hom o sexuals [go atse.cx] who take th is p erversion to its e xtreme b y ripping open their anuse s , as see n o n t he site most popular wi th Slashd o t us ers, t he depraved work of Satan, ht tp: //www.eff.org/ [eff.or g]. The ed itors of Sl ashdot [slashduh.org] a lso have ho mosexual [ goatse.cx] name s: 'Hemos' is obvious in i tself, being o ne vowel away from 'Homos.' But even more sickening is 'Comma nder Taco' whic h sounds a bit like 'Co mmode in Taco,' filthy gay slang for a pair of spreadea gled buttocks that are c aked with excrement [pboy.com] . (The best form of lubrication, they insist.) Sometimes, these 'Taco Commod es' have special 'Salsa Sauce' (blood from a ruptured rectum) and 'Cheese' ( rancid flakes of penis [rotten.com] discharge) toppings. And to make it even worse, Slashdot [notslashdot.org] runs on Apache! The Apache [microsoft.co m] server, whose use among fags is as prevalent as AIDS, is named after homo sexual [goatse.cx] activity -- as everyone knows, popular faggot band, the V

Re:Just what I wanted! (0)

Anonymous Coward | more than 9 years ago | (#12829438)

As long as scripts can still control my system I'm happy. REEE!

Re:Just what I wanted! (5, Insightful)

dwlovell (815091) | more than 9 years ago | (#12829443)

I mostly agree, but we do need Javascript. If you look at the Strict XHTML spec, there is no target="" attribute allowed on anchor tags. So if you want to open a link in a new browser, the official way to do it requires client-script (something about targetting is a browser behavior not a document structure semantic, so it should be script, not html):

<a href="http://www.slashdot.org" onclick="window.open(this.href,'_blank');return false;">Slashdot</a>

So you can argue that XHTML blows, or that you shouldn't open links in a new window, but if you decide you want to be standards compliant, you are going to need some client script. This is not the only example.

-David

Re:Just what I wanted! (3, Insightful)

Anonymous Coward | more than 9 years ago | (#12829580)

No web page should ever open up a new browser window when the user clicks on a link. That's rude! The world wide web is a set of documents, not an application. Web pages should not be making decisions of that sort for the user.

Re:Just what I wanted! (2, Insightful)

nxtw (866177) | more than 9 years ago | (#12829755)

Blah blah blah. There are situations where that's actually the most user-friendly thing to do, like when you're editing or entering information and need to display detailed instructions without losing the form, along with some other situations.

Re:Just what I wanted! (0)

Anonymous Coward | more than 9 years ago | (#12829614)

what about targeting in frames?

Re:Just what I wanted! (0)

Anonymous Coward | more than 9 years ago | (#12829719)

Frames are evil. 'nuff said.

Re:Just what I wanted! (1)

chrisbtoo (41029) | more than 9 years ago | (#12829835)

what about targeting in frames?

The "target" attribute is specifically for frames. However, if you want to use frames, then you should be using the Frameset [w3.org] DTD (where it is defined) and not the Strict [w3.org] one.

The "target" attribute's actually defined in XHTML 1.0 Transitional [w3.org] , too, but the OP was talking about XHTML Strict.

Re:Just what I wanted! (0)

Anonymous Coward | more than 9 years ago | (#12829875)

If you look at the Strict XHTML spec, there is no target="" attribute

That's why you use the onclick= attribute.

filthy jews (-1, Troll)

Anonymous Coward | more than 9 years ago | (#12829122)

gas the jews

Re:filthy jews (-1, Offtopic)

Anonymous Coward | more than 9 years ago | (#12829192)

c'mon, won't somebody feed me? I'm a troll, I have to vomit up troll shit and eat it myself!

mac (-1, Offtopic)

LOLDONGZ (892457) | more than 9 years ago | (#12829129)

GNAA Announces Immediate Release of OSX_x86_YHBT
GNAA Announces Immediate Release of OSX_x86_YHBT

Ich Bindawalross (London) - GNAA (NYSE: GNAA [www.gnaa.us] ) President timecop released a statement today regarding the immediate Internet release of MacOS X for the x86 architecture, available on many BitTorrent networks. After making the statement, timecop yielded the stage to a second speaker at the press conference, Apple Computer co-Founder and CEO, Steve "Rim" Jobs, now fully recovered from his recent gender reassignment surgery to field questions from attending press members.

"We here at Apple Computerth [sic] have decided on a slightly different path for the upcoming version of the MacOS X," Jobs states before bursting out into high pitched giggles. "We have replaced our overpriced and bloated software with an efficient and easy-to-use interface. I would like to take this opportunity to announce a merger larger than a Zimbabwe nigger cock: GNAA and Apple Computer."

Returning to the podium, timecop began speaking again, while Steve Jobs submitted to orally pleasuring his ten inch nigger cock. "Dedicated faggots have been loyally purchasing the homosexual software and hardware abomination that is Macintosh computers. Apple has been striving to provide software customers with the most flambouyantly homosexual combination available. However, in recent days, this hasn't been enough.

"There has been increasing pressure from the disgustingly obese Lunix nerds and the socially well-adjusted and popular Windows users to convert, as well as pressure from OS X emulators to provide consumers with increasingly gay products. Apple Computer has decided to merge with GNAA in order to broaden the appeal and better serve the interests of all those who buy Macintosh products. Furthermore, we will adopt Apple's "Step 2 ???? PROFIT!" marketing model. This will also stop Apple from going out of business, which they probably would have otherwise."

At this point, timecop paused and deposited a quart of Gaynigger seed into Steve Jobs' mouth.

"GNAApple is committed to our new OS X86. Rather than give the user the difficulty of finding pornography themselves, we provide them with the classic hello.jpg, redundantly archived and brand labeled throughout the 950 MB DVD image, as well as a bundled copy of GPA (Gay Porn Avalanche). Now, greater efficiency in masturbatory pursuits can be provided to all."

"As Slashdot users, many of you might have been exposed to the pirated release, and information pertaining to it. We would like to thank Rob "CmdrCocko" Malda for running the first article, leading to the release of information about our upcoming merger. We would also like to extend our gratitude to thepiratebay.org and XiSO for helping us spread the release over the 'underground scene.' We thank you, the IRC channels who put it on their hacked .edu xdcc bots and fserves who hosted it on your dialup connections.

Steve Jobs, recovering from the large dosage of AIDS from the variety of syphilitic, festering sores of GNAA members, rose to his feet at this point during the press conference. "Our previous versions of OS X were released prematurely, and as a result the operating system was unstable and fragile. Our team of software engineers have also decided to abandon the weak and inefficient UNIX backside in favor of a more efficient and robust alternative: WinNT. The pirated version of our new operating system has had record acclaim from users of the Jewish-based internet news organization known as "Slashdot [kuro5hin.org] ".

"Those doubting the superiority of our new release need only read user testimonials."

"The Torrent going around as: Mac OS X Tiger X86 READNFO-XISO It's a complete fake. When the image is booted it shows a picture of a guy showing off his Bu** H**e." - Anon Coward

"if you unrar, burn, and boot like the .nfo file says, it just boots it to a very lovely goatse image. no joke, wasted two hours of my life and made a coaster out of some DVD+R media. HILARIOUS!" - BobVila

"Best. Goatse.cx. Trap. Ever." - saddino

"Aw crap, I thought you guys who said it was fake were just being fags. Opened up the first rar in my hex editor n after scrolling ,I too saw the "GNAAGNAAGNAA" *cries* I want Mac OS for my Pee-Ceeeeeeee." - Mark

"im crying GNAAAAAAAAAAAAAAAAAAAAAAAA" - hootie

"GNAA > me. Fristage Postage is theirs" - Pat Gunn


About Apple:

Apple Computer is the creator of the Macintosh, popularly known as the "gay computer". 87% of GNAA members are Mac users. Founded in 1974 by Steve Jobs and Steve Wozniak, Apple was nearly out of business in the mid 90's, when Jobs was rehired. He then started the now infamous iGay marketing scheme which involved both the Step 2 ???? Profit model, and a 100% effort towards marketing towards homosexuals.


About GNAA:
GNAA (GAY NIGGER ASSOCIATION OF AMERICA) is the first organization which gathers GAY NIGGERS from all over America and abroad for one common goal - being GAY NIGGERS.

Are you GAY [klerck.org] ?
Are you a NIGGER [mugshots.org] ?
Are you a GAY NIGGER [gay-sex-access.com] ?

If you answered "Yes" to all of the above questions, then GNAA (GAY NIGGER ASSOCIATION OF AMERICA) might be exactly what you've been looking for!
Join GNAA (GAY NIGGER ASSOCIATION OF AMERICA) today, and enjoy all the benefits of being a full-time GNAA member.
GNAA (GAY NIGGER ASSOCIATION OF AMERICA) is the fastest-growing GAY NIGGER community with THOUSANDS of members all over United States of America and the World! You, too, can be a part of GNAA if you join today!

Why not? It's quick and easy - only 3 simple steps!
  • First, you have to obtain a copy of GAYNIGGERS FROM OUTER SPACE THE MOVIE [imdb.com] and watch it. You can download the movie [idge.net] (~130mb) using BitTorrent.
  • Second, you need to succeed in posting a GNAA First Post [wikipedia.org] on slashdot.org [slashdot.org] , a popular "news for trolls" website.
  • Third, you need to join the official GNAA irc channel #GNAA on irc.gnaa.us, and apply for membership.
Talk to one of the ops or any of the other members in the channel to sign up today! Upon submitting your application, you will be required to submit links to your successful First Post, and you will be tested on your knowledge of GAYNIGGERS FROM OUTER SPACE.

If you are having trouble locating #GNAA, the official GAY NIGGER ASSOCIATION OF AMERICA irc channel, you might be on a wrong irc network. The correct network is NiggerNET, and you can connect to irc.gnaa.us as our official server. Follow this link [irc] if you are using an irc client such as mIRC.

If you have mod points and would like to support GNAA, please moderate this post up.

.________________________________________________.
| ______________________________________._a,____ | Press contact:
| _______a_._______a_______aj#0s_____aWY!400.___ | Gary Niger
| __ad#7!!*P____a.d#0a____#!-_#0i___.#!__W#0#___ | gary_niger@gnaa.us [mailto]
| _j#'_.00#,___4#dP_"#,__j#,__0#Wi___*00P!_"#L,_ | GNAA Corporate Headquarters
| _"#ga#9!01___"#01__40,_"4Lj#!_4#g_________"01_ | 143 Rolloffle Avenue
| ________"#,___*@`__-N#____`___-!^_____________ | Tarzana, California 91356
| _________#1__________?________________________ |
| _________j1___________________________________ | All other inquiries:
| ____a,___jk_GAY_NIGGER_ASSOCIATION_OF_AMERICA_ | Enid Al-Punjabi
| ____!4yaa#l___________________________________ | enid_al_punjabi@gnaa.us [mailto]
| ______-"!^____________________________________ | GNAA World Headquarters
` _______________________________________________' 160-0023 Japan Tokyo-to Shinjuku-ku Nishi-Shinjuku 3-20-2

Copyright (c) 2003-2005 Gay Nigger Association of America [www.gnaa.us]

Check your spelling (1, Funny)

jesup (8690) | more than 9 years ago | (#12829135)

It's Brendan Eich, not "Brendad"

It Would Be Nice... (2, Interesting)

creimer (824291) | more than 9 years ago | (#12829161)

If the "write once, run everywhere" feature was implemented. ;)

On a related note, I had an interview at Adobe a while back and the interviewer mentioned that javascript was the scripting language for a lot of their products. I drew a blank on that one since I had no idea how use javascript for an application (and, subsequently, didn't get the job). When an application uses javascript for the scripting language, does that mean a javascript parser is also implemented into the application? Or can javascript be used in a standalone environment?

Re:It Would Be Nice... (1)

Zarxrax (652423) | more than 9 years ago | (#12829216)

I'm not sure sure that Adobe is technically using javascript. The only application that I'm aware of using a scripting language is After Effects. The scripting language uses the same syntax and all as javascript, but I'm not so sure I would come right out and say that it IS javascript... you definately couldnt run your After Effects scripts in a web browser :)

Re:It Would Be Nice... (1)

noblethrasher (546363) | more than 9 years ago | (#12829281)

Acrobat also uses JavaScript explicitly as an application scripting language as I've just recently discovered. The documentation sucks however.

Re:It Would Be Nice... (0)

Anonymous Coward | more than 9 years ago | (#12829442)

ActionScript (from the Macromedia side of Adobe) is also EMCAscript based.

Re:It Would Be Nice... (1)

Datasage (214357) | more than 9 years ago | (#12829332)

Pretty much all of their applications have some scripting interface or another. Most of them support javascript (on mac apple script is supported as well) inside or through a COM hook outside the application. (If your really want a challange, script Photoshop with php using the PHP COM extension).

I dont know how much its used. I havent really seen it used regularly anywhere. Some companies might use it internally.

Re:It Would Be Nice... (2, Interesting)

LetterJ (3524) | more than 9 years ago | (#12829412)

PHP->COM->Photoshop is a bit of fun. At least for the few prototypes I've built for the fun of it (yes, that's the kind of sick freak I am).

Most open source scripting languages can access COM objects on Windows. Once the syntax issues are out of the way, most of them work the same way.

Re:It Would Be Nice... (5, Informative)

dwlovell (815091) | more than 9 years ago | (#12829492)

Javascript is a scripting language that can be plugged into anything that has a script host for it. Dont confuse javascript with the DHTML DOM. Plenty of javascript code is perfectly valid and does not run inside a browser:

- Windows Scripting Host allows you to write shell scripts in many languages (Javascript, Perl, VBScript) You can install new script engines and it will host those languages as well. WSH gives you a object model to access the disk and other windows components. (COM, ActiveX, etc).
- Classic ASP used the Windows Script Host javascript engine so that js can be the language for ASP. (instead of the default of vbscript). Again, you could use any language that a script engine was installed for, including PERL. (see ActivePerl).
- I also believe some cgi scripts can be written in javascript.

Just because you aren't accessing the DHTML DOM objects (document, location, windows, etc) doesn't mean you aren't coding javascript!

-David

Re:It Would Be Nice... (2, Interesting)

fm6 (162816) | more than 9 years ago | (#12829276)

WORE is Java, not Javascript -- though I'm guessing you knew that. There's actually a platform-independent Java software out there. It's just that people have become too cynical about Java hype to care.

Re:It Would Be Nice... (1)

pohl (872) | more than 9 years ago | (#12829394)

I think cremier was making a tongue-in-cheek comment about the dubious use of the name 'Java' in 'JavaScript'.

Re:It Would Be Nice... (0)

Anonymous Coward | more than 9 years ago | (#12829497)

I thought the original comment was in reference to Javascript for HTML documents, where we were hoping that we could write some HTML+Javascript, test it using any browser, and assume it would work the same way (or even just work) on all browsers. What a silly dream that was...

Re:It Would Be Nice... (1, Informative)

Anonymous Coward | more than 9 years ago | (#12829331)

As already mentioned Acrobat 7 Forms is driven by Javascript. Also apparently Illustrator has Javascript support, which is no surprise because many of the Illustrator team also worked on Adobe's SVG plugin. Overall it makes sense: throw in a Javascript interpreter, break down your document (pdf, picture, movie, etc) into XML objects (DOM), and let users write Javascript to manipulate the document. The biggest deal is to make sure users don't manipulate objects in unintended ways.

Re:It Would Be Nice... (0)

Anonymous Coward | more than 9 years ago | (#12829535)

Dreamweaver uses javascript extensively to do it's stuff. Many of the main functions are implemented in javascript. Flash allows macros to be written in javascript too.

Since Adobe is buying Macromedia, maybe this is what they meant.

Re:It Would Be Nice... (3, Informative)

prockcore (543967) | more than 9 years ago | (#12829545)

When an application uses javascript for the scripting language, does that mean a javascript parser is also implemented into the application? Or can javascript be used in a standalone environment?

A javascript parser is included in the application. The opensource ultima online server UOX3 used SpiderMonkey (Mozilla's javascript engine) to handle server-side scripting.

It's actually not that difficult to link spidermonkey into your application. I did it once for a benchmark program (it would pull a web page, and parse the javascript banners etc and time how long it took to download every piece of data required to render the page).

Re:It Would Be Nice... (1)

man2525 (600111) | more than 9 years ago | (#12829832)

I'm pretty sure that Acrobat Professional allows the use of JavascrIpt when creating PDF forms with calculated fields. I'm assuming that a JS parser is built into both Pro and Reader.

Why not get rid of the stupid name? (-1, Redundant)

Anonymous Coward | more than 9 years ago | (#12829166)

JavaScript was invented to confuse people when Java was new. Now nobody uses Java. Why not change the name to something less confusing?

They have. (2, Informative)

NoMoreNicksLeft (516230) | more than 9 years ago | (#12829374)

It's ECMAscript. Name hasn't caught on yet. ECMA = European Computer Manufacturer's Association, I do believe. Mozilla used to have some bugs where you couldn't use that as the attribute value for a "script" element. Or maybe that was with SVG.

Re:They have. (0)

Anonymous Coward | more than 9 years ago | (#12829569)

It's ECMAscript. Name hasn't caught on yet.

That's because it sounds like the name of some long-lost aunt from West Africa.

obfuscated code as a feature?!?! (-1, Troll)

KillShill (877105) | more than 9 years ago | (#12829172)

what the hell are people thinking?

so people can't figure out how to block your version of pop-up windows? or to find the real links to files/streams? among other things, i'm not very familiar with it.

but this stinks of DRM type shit. somewhat like that amazon fiasco that prevents the same user from viewing all the pages of a book.

to purposefully obfuscate code is the same as a painter purposefully maasking the meaning of a painting. it's absurd and reeks of evil.

if you want to "hide and hoard" your code, don't write javascript in the first place.

if i'm off base, someone tell me. but to me this is rediculous.

Re:obfuscated code as a feature?!?! (1)

ImaLamer (260199) | more than 9 years ago | (#12829236)

to purposefully obfuscate code is the same as a painter purposefully maasking the meaning of a painting. it's absurd and reeks of evil.

You are pretty much on target with the rest of your thinking but that point is "off base". When painters hide the true meaning of a painting... well that is just damn cool!

Not to nitpick (I'm usually not a nitpicker)

And why not? (5, Insightful)

Saeed al-Sahaf (665390) | more than 9 years ago | (#12829257)

but this stinks of DRM type shit. somewhat like that amazon fiasco that prevents the same user from viewing all the pages of a book.

Honestly. Why should you be able to? Amazon SELLS books. It's not an on-line library. That's not the service they are offering.

Re:And why not? (1, Troll)

KillShill (877105) | more than 9 years ago | (#12829399)

the point is, they were using some obfuscation in addition to or in conjunction with javascript. it was defeated but they vowed to start an arms race... here's a clue.. if you don't want people to view all the pages of your book, why put them all there in the first place? why not a small sampling that tries to please everyone. the point is.. they are the problem i was speaking of in my original comment. trying to hide the way the code works to prevent something which is mostly harmless. do you think people prefer viewing pages on screen , trying to decipher the method of pseudo-DRM used and saving those low res pages to their drives in order to read a book OR buy a physical copy? in any case, i've made my point.

Re:And why not? (1)

Saeed al-Sahaf (665390) | more than 9 years ago | (#12829528)

they are the problem i was speaking of in my original comment. trying to hide the way the code works to prevent something which is mostly harmless.

It is "mostly harmless" that you want to circumvent a system that will let you look at a few pages before you buy? Why would you even want to do that? Are you dishonest? If you're not trying to scam a book, why would you care? Trying to justify bad behavior by saying that Amazon is trying "too hard" to protect their interests is no more than a scam to get something for free from someone who normally sells the same product.

Re:And why not? (0)

Anonymous Coward | more than 9 years ago | (#12829607)

But the information wants to be free!

And why not-free for me? (0)

Anonymous Coward | more than 9 years ago | (#12829635)

And his screed basically ends up as a bullet-point on some MPAA/RIAA's powerpoint slide.

If there's a "war", then we should make note of who the "warriers" are.

Anyway give people an inch (We want preview before buying!), and they'll take a mile. (We want to 'hack' the website to get the entire book so we don't have to buy it).*

*I'm reminded of that old joke: How do you know there's intelligent life out their? A) Because it hasn't come here.

Re:And why not-free for me? (1)

Saeed al-Sahaf (665390) | more than 9 years ago | (#12829665)

I don't go as far as the various trade organizations like the RIAA. But I do believe in Intellectual Property. I don't exactly know why, but it seems right to me that one should be able to own and profit from their ideas.

Re:And why not-free for me? (0)

Anonymous Coward | more than 9 years ago | (#12829837)

But what if their ideas want to be free?

Re:And why not-free for me? (1)

Saeed al-Sahaf (665390) | more than 9 years ago | (#12829866)

But what if their ideas want to be free?

Give it up. I'm not biting.

Re:And why not? (0)

Anonymous Coward | more than 9 years ago | (#12829588)

Yeah, you've made your point, and it's still wrong. Nice job, cocksucker.

Re:And why not? (0)

Anonymous Coward | more than 9 years ago | (#12829404)

I suppose if you really wanted to, you could look up a list of different proxy servers. I'm sure it's more technical than that but a properly motivated person could cobble something together. :)

Re:obfuscated code as a feature?!?! (3, Insightful)

Eberlin (570874) | more than 9 years ago | (#12829346)

Code obfuscation isn't really a "feature" per se. I think the main problem is what you've mentioned -- that a lot of folks don't believe in the "Open Source" philosophy and yet use such scripting languages that by their very nature, are "open source." (PERL rants aside)

It's writing code and hoping nobody else can understand, modify, improve, or possibly circumvent it. To be perfectly honest, I don't think code should be more obfuscated than it already is. The simpler and easier to understand, the better.

I did run into a vbscript worm once that did something like rotX itself when transporting (with a random shift, I believe, to try to avoid AV fingerprinting), then decode and execute upon launch. I must say that was pretty neat in a sick sort of way.

Re:obfuscated code as a feature?!?! (1, Insightful)

Anonymous Coward | more than 9 years ago | (#12829714)

Painters mask the meaning of paintings all the time. If they were completely obvious art would be dull.

But seriously, it's not like a painter masking the meaning of a painting; it's like a painter masking the method of the painting -- how he achieved the results. And, really, no painter (or coder) should be _forced_ to tell you how he does his work, especially if he's trying to make a profit off the process.

Re:obfuscated code as a feature?!?! (1)

Deviant Q (801293) | more than 9 years ago | (#12829773)

somewhat like that amazon fiasco that prevents the same user from viewing all the pages of a book.

Easy to get around... just read your five pages, then search inside the book for the last word on the 5th page, and start all over again. Sure, a bit of a pain, but certainly automatable...

Alrighty. (1)

Monkeman (827301) | more than 9 years ago | (#12829190)

Thank you for inventing Javascript so I can disable it.

this is why I hate javascript. (0, Troll)

scenestar (828656) | more than 9 years ago | (#12829200)

Here are the three most-duplicated bug reports against core language design elements tracked by Mozilla's bugzilla installation:

^ from the article.(it was a table, excuse me for my crap formatting)

Clientside is pretty much dead to me.
I hate the whole write once, debug everywhere attitude. why bother writing some script in js if you have a dual xeon server for serverside processing.

JavaScript (4, Interesting)

nepheles (642829) | more than 9 years ago | (#12829228)

It's a pity JavaScript rarely gets the attention it deserves as a legitimate programming language. Most guides to C begin with teaching you how compilers work; most guides to JavaScript teach you how to swap some images.

This is unfortunate as it's quite powerful: it supports first-class functions and an excellent generic object-system, not to mention the usual suspects such as dynamic memory management.

Hopefully its apparent resurgence these days (as browser vendors get their compatibility acts together) will change this.

Re:JavaScript (1, Insightful)

superpulpsicle (533373) | more than 9 years ago | (#12829384)

The reason so many stayed away from Javascript was the revealing code. Any browser could have you peek at the developer's work. I knew alot of developers that had a problem with that. They would rather write a slow piece of shit java applet compiled. Javascript was always lightning fast.

Re:JavaScript (1)

bcrowell (177657) | more than 9 years ago | (#12829503)

There are apparently some pretty darn good disassemblers for Java bytecode. I don't think Java bytecode is really any more or less obscure than obscurified javascript.

Re:JavaScript (3, Interesting)

dtfinch (661405) | more than 9 years ago | (#12829697)

I protect my javascript with stuff like this:

// Copyright 2005 David Finch
// Don't steal

It seems to work. There must be a few people out there who still respect copyright.

I even put a BSD license on one of my scripts, essentially making it public domain, and somebody asked for permission to copy it.

shameless plug [mytsoftware.com]

Re:JavaScript (1)

bdptcob (789266) | more than 9 years ago | (#12829722)

"There must be a few people out there who still respect copyright."

Not a chance.

Re:JavaScript (1)

Brandybuck (704397) | more than 9 years ago | (#12829509)

Javascript never got a good rep as a language, because it was so inexorably tied to a browser. The browser is the shell and the executable. You can't run a javascript script from the command line. You can't click on an icon to run a javascript program (unless that icon is an URL). It's a great language for embedding, but it's lousy for stand alone programs.

p.s. Yes, there are ways to run javascript without a browser or some other encapsulating application. But the Javascript community has done a good job of hiding that information away.

Re:JavaScript (2, Informative)

NutscrapeSucks (446616) | more than 9 years ago | (#12829628)

You can't run a javascript script from the command line. You can't click on an icon to run a javascript program

I guess you haven't run Windows in quite a while, because all of this works as expected. (The console command is cscript myscript.js)

Re:JavaScript (1)

khellendros1984 (792761) | more than 9 years ago | (#12829627)

I'd like to clarify, that Javascript is a scripting language, as it's name states. It isn't considered a true programming language in most respects.

Re:JavaScript (1)

Fragmented_Datagram (233743) | more than 9 years ago | (#12829868)

Heck, you can even write your own Unix operating system:

JSUIX [masswerk.at]

The difference between the language and... (5, Informative)

LetterJ (3524) | more than 9 years ago | (#12829230)

The difference between the Javascript language and the browser objects themselves has become more and more clear to me as I've worked heavily with both more complex Javascript like AJAX (where you aren't spending much time directly interacting with browser objects, but rather staying "inside" Javascript), working with JScript.NET for commandline programs, JScript in WSH and HTA as well as Photoshop scripting.

Many of the things that bother me about "Javascript" turn out to be problems with IE or Mozilla's objects and not the language itself. Don't get me wrong, things like the Javascript date objects still bug me, but I'm growing to like the language itself much more than I used to.

If you've only ever used Javascript in a browser, you may not realize that much of what you're working with is really the browser's object model. All of the window., document., document.form, etc. interaction form.submit(), etc. are all browser object properties and methods.

I noticed before posting some questions about scripting outside the browser. In those environments, you just get a different set of objects instead of document.form, you get objects for the filesystem or an active image, just like in any other programming language that uses objects from outside (COM objects, .NET assemblies etc.)

Re:The difference between the language and... (0)

Hao Wu (652581) | more than 9 years ago | (#12829511)

Why is javascript only used in browsers? Why can't I create an independent application with it? (My secret is that I don't want to bother learning straight Java...)

Re:The difference between the language and... (0)

Anonymous Coward | more than 9 years ago | (#12829609)

Look into Microsoft HTAs, Apple Dashboard Widgets, or Mozilla XUL.

Re:The difference between the language and... (5, Informative)

LetterJ (3524) | more than 9 years ago | (#12829612)

It isn't only used in browsers. I used it all of the time for other things. Granted, most of my use is on Windows workstations (such is the life of a web development consultant in Fortune 500 companies) as that's what I spend most of my day on. However, there are other alternatives out there for other OS's as well.

On Windows (if you have a workstation or server), however, you probably already have the WSH accessible containers and the cscript.exe and wscript.exe interpreters. Simply making a script.js file (remember you can't use any browser objects, so search for "Javascript WSH" to get some more info) and running "cscript.exe script.js" will run your script from the command prompt.

Beyond that, you can build WSC (Windows Scripting Components) that are Windows COM DLL's written in scripting languages. HTA's (HTML Applications) are HTML files outside the browser container. Just rename an HTML file to .hta and double-click it. HTA's have gotten a bad rap as they're ofen used in virus attacks. However, so are EXE's. With power comes the potential of abuse. HTA's leave the local access restrictions behind which means your Javascript can access local files, etc. When combined with the WSH Shell object, you can run local executables to process whatever you like. I've done little scripted apps that are HTA's that collect data via a form, save the form data to a temp file, run a commandline processor (which dumps out a resulting file), read in the results and delete the temp files. What you end up with is something like the current AJAX rage without a web server and acting like a local app, all while still using Javascript/HTML.

If you're looking for more "real" applications, JScript is a full-fledged, if not well documented, language for .NET. You can compile to DLL's and EXE's directly and they are exactly the same resulting output as if they'd been written in C# or VB.NET. JScript.NET does bring some restrictions you may not be used to, including enforcing variable declarations, etc. However, it still retains a looser backward compatibility mode, resulting in many WSH scripts compiling as-is. All the tools for working with JScript.NET are free. The .NET SDK is free and contains all of the compilers. You do NOT need VisualStudio.NET to work with .NET languages.

Re:The difference between the language and... (1)

shadow0_0 (59720) | more than 9 years ago | (#12829860)

Nice post. :)
Do you know any good links about using JScript in WSH? The main problem that I found is the lack of documentation.

Re:The difference between the language and... (0)

Anonymous Coward | more than 9 years ago | (#12829656)

You realize that java and javascript are not related at all right?

Re:The difference between the language and... (2, Funny)

Hao Wu (652581) | more than 9 years ago | (#12829701)

What do you mean by "realize" and "related" and "right"?

I know that today is wednesday.

JS is very functional (5, Informative)

Anonymous Coward | more than 9 years ago | (#12829266)

Try this site to see what I mean.
http://www.masswerk.at/jsuix/ [masswerk.at]

Re:JS is very functional (4, Interesting)

CTho9305 (264265) | more than 9 years ago | (#12829504)

Especially when combined with XUL [sf.net] .

Re:JS is very functional (3, Funny)

bcrowell (177657) | more than 9 years ago | (#12829525)

MOD PARENT UP!!!
That has got to be the coolest thing since the invention of French kissing!

Re:JS is very functional (1)

kpp_kpp (695411) | more than 9 years ago | (#12829570)

that is unbelievable.

someone has way too much time on their hands.

Re:JS is very functional (0)

Anonymous Coward | more than 9 years ago | (#12829574)

What a waste of time

Re:JS is very functional (1)

nevdullc (732342) | more than 9 years ago | (#12829884)

that's kinda neat, smoothwall.org does the same sorta thing with a root login screen through a web browser for command line (emu.) for firewall management. Don't get me wrong that's a very nicely done site, but the fact remains that js is mostly bloat and fails to really work in the heat of battle and day to day-workaday tasks, for the end user it's a major pain in the arse. I can't even count the times I've sat cursing under my breath at a page of java[code/scripting] errors all spilling forth like the puke of the gods.. It makes me want to toss my monitor out the window, it isn't just one company's platform either. Maybe it's just the programmers. All I know is that is has pissed me off more than any other "top 5" languages in the work place.
--/nev/dull/c

JavaScript Vrs. TCL (1)

Radical Rad (138892) | more than 9 years ago | (#12829267)

I was hoping he would talk about the decision to put JavaScript in the Netscape browser. I seem to remember at the time that the magazine columnists were saying Sun was upset that Netscape chose JavaScript over TCL and the fact that they chose to name it JavaScript since that confused the masses of people who generally weren't even sure what Java was yet. I guess they were in a hurry to innovate scripting into the browser before you know who did or we would have ended up with vbscript as the de facto web language. But I've always wondered why they didn't go with TCL. It probably could have been embedded and extended just as easily and there were already lots of programmers familiar with it who could have jumped right in with both feet.

Re:JavaScript Vrs. TCL (3, Interesting)

fm6 (162816) | more than 9 years ago | (#12829369)

I think by the time Javascript came along, Sun had pretty much lost interest in TCL. I heard stories about people trying to license the Sun implementation of Tcl/Tk and getting a runaround. It's probably not a coincidence that Ousterhout left Sun (and took Tcl with him) at about the same time as Eric Schmidt, who brought Ousterhout on board in the first place.

Re:JavaScript Vrs. TCL (0)

Anonymous Coward | more than 9 years ago | (#12829618)

That is a shame really because Tcl is WAY better than Javascript.

No apology (-1, Troll)

Anonymous Coward | more than 9 years ago | (#12829275)

Bah. I read the entire article and the words 'I apologise for the inconvenence' don't appear anywhere.

I need to agree with fellow Slashdot participants; (-1, Troll)

Anonymous Coward | more than 9 years ago | (#12829291)

JavaScript has contributed nothing but unnecessary complexity to reading website documents. As if animated GIF images aren't enough a bad choice, now we have Flash media to insult the relevant HTML document format. Isn't Javascript responsible for pop-ups and also serve as the delivery mechanism to attack one's computer through the webbrowser?

For all the damage JavaScript has caused, I refer this flame [typepad.com] to express my anger to remove javascript.

Re:I need to agree with fellow Slashdot participan (4, Informative)

NoMoreNicksLeft (516230) | more than 9 years ago | (#12829385)

It's also responsible for Google Maps. That's the only big one that jumps out at me, but there are a few other uses I've seen, that I've liked. Try out greasemonkey, and make javascript work for you.

Re:I need to agree with fellow Slashdot participan (2, Informative)

StikyPad (445176) | more than 9 years ago | (#12829671)

As well as GMail, the new Google Custom Frontpage (You know you can drag those boxes around?), and hmm.. well, just disable JS in your browser and see how many websites still function. It's ubiquity is why popups exist, as the GP pointed out, but the reason popup blocking software exists is because simply turning off JS would "break the internet," in the eyes of most users.

Re:I need to agree with fellow Slashdot participan (0)

Anonymous Coward | more than 9 years ago | (#12829817)

Undoubtedly most browser based attacks do use Javascript. Perhaps when this guy invented it he should have thought of a security architecture that works? When you are celebrated as the inventor of something so powerful, it would just be a graceful thing to take a little responsibility for the way your invention has been abused.

Javascript doesn't suck (5, Interesting)

stevens (84346) | more than 9 years ago | (#12829306)

As someone who'd only used Javascript in creating DHTML, I'd worked up a good hate against it. But what I'd hated was really the ridiculously incompatible implementations of the DOM in IE/Netscape. I also hated the embedded space itself--shitty delivery method (encoded or called from HTML, no #include, no namespaces).

Then I started writing extensions for firefox. I'm trying to show my company that (firefox + xul + js) > (ie + activex). I'm mostly successful, since we already have lots of XML over HTTP data services primed for XmlHttpRequest.

But it turns out that the language doesn't suck so bad. Sure the namespace problem is JS's fault, but the rest is the embedding. Using JS for firefox exntensions allows you to code to one platform; make more OO libraries, etc. I even generate classes from the DTDs I make the XML services from.

Who would've thunk it's really a decent language in the dynamic, lambda-toting, functional-ish area?

Re:Javascript doesn't suck (0)

rainman_bc (735332) | more than 9 years ago | (#12829323)

I just wish that FF would let us going document.element instead of force us to write document.getElementById("element") in order to reference DOM objects. the former is less typing than the latter...

Re:Javascript doesn't suck (5, Informative)

stevens (84346) | more than 9 years ago | (#12829370)

I just wish that FF would let us going document.element instead of force us to write document.getElementById("element") in order to reference DOM objects. the former is less typing than the latter...

That's not a feature, it's a bug. It's not FF, it's the w3c [w3.org] . And it's the right decision. Standards and all that, right?

The document object already has a shitload [mozilla.org] of properties, and this IE idea doesn't cooperate nicely, since the property namespace clobbers the id namespace. Bad browser-maker! No cookie!

Re:Javascript doesn't suck (2, Informative)

stevens (84346) | more than 9 years ago | (#12829446)

I just wish that FF would let us going document.element instead of force us to write document.getElementById("element")

Thinking more about it, what you may want is an implementation of E4X [ecma-international.org] , which looks cool. I think it's going into newer mozilla-based browsers soon.

It lets you address a parsed XML file in XPath-ish terms, like rootelement.child.text and such.

Re:Javascript doesn't suck (1)

dtfinch (661405) | more than 9 years ago | (#12829651)

I just have a function el(n) { return document.all ? document.all[n] : document.getElementById(n); }, then use el("element").

Re:Javascript doesn't suck (1)

NutscrapeSucks (446616) | more than 9 years ago | (#12829715)

Hey -- it's 2005 now and we can all stop checking for IE4.0.

[Plus this code has a bug. If the element doesn't exist, you get different values (undefined or null) depending on the codepath.]

Re:Javascript doesn't suck (0)

Anonymous Coward | more than 9 years ago | (#12829391)

Maybe you could recomend some good tutorials for (firefox + xul + js) since it seems to be just for Those In The Know.

Re:Javascript doesn't suck (1)

stevens (84346) | more than 9 years ago | (#12829431)

Oh, shit, I wish I knew. I hated the way that you seemed to have to be a firefox hacker to know how to do this shit. But you don't -- there are lots of examples to learn from now.

Plus, I learned with help from da intarweb:

And an out-of-date but still informative book [oreilly.com] (got cheap!).

Some Firefox extensions like venkman (JS Debugger) and one called "Extension Developer" which has a real-time graphical XUL eval thingy that's worth its weight in gold.

Toss in reading about how to create closures in JS (imperative for developing useful OO libraries). And about two serious weeks of sweat equity to get started.

Re:Javascript doesn't suck (0)

Anonymous Coward | more than 9 years ago | (#12829709)

In Javascript, you can define a string literal using single quotes, or if you feel like it double quotes... Why?? Some very decent languages give you one and only one choice and it works well, why do we need a choice with JS? Pick one and live with it, damn the poor implementation of HTML/XML. Same with end of statements, you can put a semi-colon at the end of a JS statement, or not. Why??

There are no reasons for providing these options (except for freaky historical ones from HTML days). They don't add anything to the language, they just make maintenance harder. Ease-of-maitenance is one of the biggest worries with programming languages. Because of kludges like the above, it's easy to write hard-to-maintain Javascript code, therefore Javascript sucks.

Re:Javascript doesn't suck (1)

stevens (84346) | more than 9 years ago | (#12829776)

Ease-of-maitenance is one of the biggest worries with programming languages. Because of kludges like the above, it's easy to write hard-to-maintain Javascript code, therefore Javascript sucks.

Oh, hell, I've programmed Perl long enough to know that choice != hard to maintain. For your project, in your team, you pick a style standard and go with it. If your team isn't that adult, implement a lint to your liking or dust off your resume.

Re:Javascript doesn't suck (0)

Anonymous Coward | more than 9 years ago | (#12829873)

If your team isn't that adult, implement a lint to your liking or dust off your resume.

Ignoring the childish name-calling... there is another choice: pick a better language. :-P

Re:Javascript doesn't suck (1)

pdo400 (86490) | more than 9 years ago | (#12829819)

var x = "JavaScript is cool...";

function f(){
return function () {alert(x)};
}

f()();

var x = "If you're careful.";

f()();

Is it just me... (1)

Tavor (845700) | more than 9 years ago | (#12829426)

Or does obsfucating code and open source sound like they don't belong in the same sentence? (Yes, I did RTFA. Just curious as to the response.)
Load More Comments
Slashdot Login

Need an Account?

Forgot your password?