« first day (442 days earlier)      last day (4731 days later) » 

00:33
0
Q: JavaScript (jQuery) And CSS Styling

ryanzecLets say I am building a jQuery plugin that has a number of non-configurable css attributes it needs to apply to DOM elements the plugin itself creates. Is it consider better practice to apply the css directly in the javascript code or is it better to create a css file and just include both the ...

Happy new year.
still have 5 hours
but out of curiousity did the world come to an end when new year struck for you?
yep, ended over here
was a pretty short event though
kinda interesting inside the void#
 
2 hours later…
02:25
RT @devongovett: Published my epic Badass JavaScript Year In Review: http://badassjs.com/post/15082876071/2011-a-badass-javascript-year-in-review Read it and retweet! <3
02:59
So I'm returning an object from a function and getting undefined. But if I console.log(obj) instead of return, I get the object. Am I going crazy?
RT @pornelski: Ladies and gentlemen, I present you the new pngquant home page: http://pngquant.org
03:51
hi
 
1 hour later…
05:14
0
Q: Copying section of map array

Chris EvansI'm experimenting a bit with pathfinding. I'm using Javascript. I have a map array as follows: mapArray = [ [0, 0, 0, 1, 1, 0], [1, 0, 0, 1, 0, 0], [0, 1, 0, 1, 1, 0], ]; The map is fairly excessive in size and I would like to take out a porti...

 
1 hour later…
06:42
RT @ezufelt: Excellent discussion on WAI-ARIA, role="application", passing keys to the browser, and screen-readers - http://tinyurl.com/8yhr9o2
 
4 hours later…
10:22
RT @annevk: New year present from @BrendanEich https://mail.mozilla.org/pipermail/es-discuss/2011-December/019112.html #ecmascript #versioning
how Facebook wall does not let the server respond to ajax and hangs the connection unless there is an update?
11:10
Apple/WebKit video dev Eric Carlson adding support for clipping of video/audio so only a certain time range is played https://bugs.webkit.org/show_bug.cgi?id=65838
11:32
ugh
Is it worth having make and beget as sugar? or should I just use the more verbose option?
11:47
RT @annevk: ECMAScript without versioning was figured out by @littlecalculist, @BrendanEich just let me know. So thanks @littlecalculist!
12:16
in iPhone / iPad, 2 days ago, by furqan
wait m cuming
12:46
TMI
Read this book (Kelly Link, Stranger Things Happen. it's licensed under CC.) Seriously. Read it
13:48
0
Q: jsfiddle explanation

nK0deI recently started learning JavaScript on my own and jsfiddle has been a huge help to me with experimenting with code. Although it's pretty simple, I still have one problem understanding its events. ex: no wrap (head), onDomReady (The dropdown list that's displayed at the top left corner of the i...

 
3 hours later…
17:01
1
Q: Increase performance for this keyup function?

khtI have a keyup function that expands an input field as text is added. There are a lot of fields where this code will be applied, what is the best way to write this for best performance? Here is a working demo: http://jsfiddle.net/J9Ner/ $('input.name','#bakery').live('keyup', function() { v...

17:23
Hi
What is the best way to code a web page (application) when you have a "top bar", the blue/black you are familiar with from iPhone? Should I use percentage in height?
I want it to look decent on many different screens
 
1 hour later…
18:38
0
Q: Is there a way to use e.pageX/Y in a keyboard event?

Gabriel A. ZorrillaI'd like to move a cursor inside a canvas with the keyboard. I do it with the mouse, but now i want to pickup where i left the mouse and move it with the keyboard arrows. If i want to use event.pageX from inside the keypress function, it's undefined, even thougg its defined when the mouse is mov...

19:01
Why can you not copy a class (*.java) from a project that has a web service and put it into another project that uses that web service so you can use the class in a generic constructor?
Even though the classes are identical NetBeans will say Expecting webService.class Instead this.class found.
I learned you can just get the class type through the web service but I was wondering why it won't accept a local class that's an identical match. Is it because their serials don't match?
And you're asking this here because this is obviously the Java room
Java is dead
When the bakery's closed, you don't go to the florist because it's the closest thing that's open
6
Is there anyone around that isn't being sarcastic?
Well, unless you're a cow
19:07
Perhaps in the future you should just say you don't know.
But then again, I don't think cows grasp the meaning of work hours
I don't know. Why would I know? It's not like you've given any data, just that you've moved a file. But you probably shouldn't bother, because the florist doesn't make pies
It's confusing how you can know javascript and not java
It's confusing how you can know Java and think Javascript is, in any way, related
It's confusing how you can find that confusing
troll ...
19:15
ahhhhhhhh
people, stop porting code if you have no idea about JS :(
The names and naming conventions are the same. Both are object oriented. Both are based off c. The only difference I see is that one is client side and the other is both. But the same rules apply.
"Perlin noise seems to be reasonable fast in JS, too"
yeah sure, 5 minutes and I already got a 3x improvement on the Java port, dude
...javascript is not anything like java. Just because they're OOP doesn't mean they're siblings. js is a lot more like Lisp than like java.
use array.slice people!
Don't copy the values into a new array :(
Java is only slightly more OO than C.
19:18
U can haz memcpy u know
@adscriven i agree
@TravisMeyers "But the same rules apply." Eh?
@TravisMeyers javascript is not based on C
JavaScript is a prototype-based scripting language that is dynamic, weakly typed and has first-class functions. It is a multi-paradigm language, supporting object-oriented, imperative, and functional programming styles. JavaScript was formalized in the ECMAScript language standard and is primarily used in the form of client-side JavaScript, implemented as part of a Web browser in order to provide enhanced user interfaces and dynamic websites. This enables programmatic access to computational objects within a host environment. JavaScript's use in applications outside Web pages ...
@TravisMeyers oh right, nothing like java then
19:23
I don't just make shit up
> JavaScript copies many names and naming conventions from Java, but the two languages are otherwise unrelated and have very different semantics.
Not to mention ideologies.
Eich took all the stupid keywords and stuff from Java to make JS "sell"
"JavaScript uses syntax influenced by that of C"
js is basically a scheme interpreter with c syntax bolted on
19:24
"JavaScript was originally developed by Brendan Eich of Netscape under the name Mocha, which was later renamed to LiveScript, and finally to JavaScript mainly because it was more influenced by the Java programming language."
It doesn't make it based on C. It only says the syntax is influenced by C. And it was renamed to javascript so that Sun won't destroy them.
can we delete the BS wiki article?
It was named "Java" because it needed to SELL
And LiveScript had problems with copyright at some point iirc
@TravisMeyers , you are clueless
as did JavaScript
But they figured that out eventually
I believe that JS originally had scheme syntax, but Eich's employers objected.
19:26
Just watch one of the 2000 talks where eich goes into the details about the development
or one of crockfords
@tereško was faster :)
The second one will fit your needs. First one is very interesting, and a recommended view no matter what, second one speaks about js as a language.
Ok. I'll watch both.
That entire talk series is awesome
19:43
LoL. He refers to the Java component as the "bad parts." He's right though. Java is sluggish and suited for beginners.
I have to learn it though. I'm in college and it's part of the curriculum.
@TravisMeyers Ahh, I was taught OOP with Smalltalk. The following year Smalltalk was axed in favour of Java. I feel quite fortunate.
@Raynos If I make the bot itself sit on the server and have the client steal and do chat stuff, will it count as cheating? Because I can't figure out the technicalities of dancing with SO
@Zirak I would assume it does count as cheating. Why don't you look at the source of the other bot ?
I fear Wetzel's bot. It summons Cthulu, and I'm not so sure how...accurate it is
the kitten always worked!!!!!
well, except for when it didn't
there are quite a few nerve wrecking timeout issues with SO chat
19:55
Doing this client-side hacking will never be accurate :-/
@adscriven why fortunate? You're not mad about that year you lost?
Does the login part work now? Can I use it to login to my account, which is registered under my Google login?
it was written for use with OpenID
But more importantly, if it does, may I steal? :P
In case you want to use google.. uh, you'll have to reverse engineer that :P
19:57
@TravisMeyers Because it is pure OO. + it's far more advanced.
@Zirak it's under MIT
Well, then help me out with this: I saw what SO does on stackoverflow.com/users/login , and simply sent a POST request to stackoverflow.com/users/authenticate with openid_identifier=https://www.google.com/accounts/o8/id
I get a 302 status code. And then I look at the console screen blankly.
@adscriven Ah. Ic. Sorry it got axed. I hear there's still a few languages around that are similar though.
@TravisMeyers Well JS was somewhat influenced by Self, which was an attempt to simplify (!) Smalltalk.
So that concludes that Self failed miserably in the end? :P
@Zirak There is some localStorage trickery involved iirc
like auth hashes and shit
20:04
@IvoWetzel Heh! Well, was it ever intended to be more than academic research?
@adscriven JavaScript? No, but I guess people will figure that out eventually :D
;)
@IvoWetzel Well, in that case, I hope they don't!
@adscriven don't feel too bad. I learned to program with BASIC
@IvoWetzel Oh wait, I think they did. ecma-international.org/publications/standards/Ecma-262.htm :-(
@TravisMeyers Hard core
@adscriven lol
20:12
posted on January 01, 2012

The Proxies API is a low-level catch-all thing that you can wrap around your objects to implement almost anything you want within the syntactic limitations of JavaScript. Firefox supports it, and so does the latest version of V8 apparently. The existential operator (the accessor kind), if…

How do people in here feel about proxies? My gut instinct is that they sound dangerous (JS ninjas will love them), but I've not personally tried them out, so I'm open to opinion.
like a reverse proxy?
Im in process of modifying apache config for reverse proxy to retrieve files from another site on one site to keep domain in address bar
its the only way to do it as i know of
unless you use frames which is out of questoin
@JohnMerlino It's not that sort of proxy. See the link from Feeds above.
(Realising now that I should have done a 'reply'.)
21:03
@Zirak o.o that is cheating
cmon you have a reference project, @IvoWetzel kitten works. Just copy paste tweak
@TravisMeyers man you remind me how about 5 months ago I would bash on Java and Java programmers, as if you know java programmers are stupid or less good or dummed down. At some point you realize that java is a tool that can be used. And in some cases Java is the correct tool
@adscriven my gut instinct to proxies is 'Are they as slower as getter/setters?'
proxies are awesome, bloody awesome but they look slow as hell
@adscriven ES DOM implementation made possible by proxies
Mind you proxies don't go into application code, they are a library level tool
@Incognito why I can no comment on your blog?
21:19
@Raynos But but but ;_;
@Zirak are you a competent developer? Are you a person who I expect better from?
Damn you and your art of persuasion
...I'll do it!
@Zirak all I'm saying is I have you in my mental competent list. Would you like to be removed from it?
21:51
So, to log into SO, I need to programatically log into Google first. That's gonna take some time. Yummy
@Raynos do you mean "mentally competent list"
they may be something wrong with your spailing
22:08
i cant believe such a basic question like this received so many votes:
115
Q: Newbie Javascript : appending to array

interstarHow do I append to an array in Javascript?

23:01
@Raynos Looks like the template doesn't have it, I'll investigate.
what text editor do people use to write javascript in and then post a link in forums?
@Raynos updated.
I have an issue. I am using google visualization and when the chart first loads, it renders fine. Then when I perform a refresh, I pass in the same exact data again and instead I see a little red error box instead of chart and nothing else, no errors and no errors reported by firebug. Here is the relevant code: jsfiddle.net/johnmerlino/YCqyG
Im pretty sure it goes wrong with the draw method of the Charts instance. But I look closely and cannot detect a problem with it.
The information I provide above is sufficient for a question on stackoverflow? I'd hate to post a question and it be too vague, but I cannot providing a live working example because too much dependencies.
thanks for any response
23:20
@TravisMeyers I mean I have a list in my head, a mental list
mentalist?
23:40
Hi all....anyone got IE9 to hand?
nop
oh yes I do
I’ve got a FB like plugin on a site I’m working on..
works in IE7 and 8, but 9 is playing up on this laptop I test stuff on (might be the laptop)
lmpetersfield.co.uk/home.php - would you mind taking a look on this page? It’s in the footer.
kind of works
that’s encouraging :\
What do you see..?
all I can think is calling that draw method twice, but why should that matter
everything else seems to be fine

« first day (442 days earlier)      last day (4731 days later) »