« first day (3 days earlier)      last day (4944 days later) » 

12:15 AM
Hey guys. Would you recommend any frameworks for creating a Javascript "grid" for a simple game? I want to practice my JS by creating a grid-type game where one can place blocks on a grid, but Googling just gives really old Javascript results
Raphael JS might be what I'm looking for, bot not sure if it's optimal
 
12:34 AM
Are the jQuery UI buttons showing the icons for anyone else? jqueryui.com/demos/button/#icons
 
when I look at the UI demo for buttons, the icons are missing. Is it me or everyone?
nevermind. Firebug is telling me it's everyone as the sprite is missing
 
 
2 hours later…
2:48 AM
ok it is time to play let's find rchern's stupid mistake!! i took jQuery UI's combobox demo code and made the value of each item different from the text. in the select function, $(this).val(ui.item.label) should use the text rather than the value. console logs seem to indicate everything is ok, but i see the value rather than the label in the input textbox.
 
3:17 AM
@rchern The default handlers will fill in the value using ui.item.value, and you don't cancel the event by returning false from your custom handlers. The value gets updated with what you expect, but then is immediately replaced.
 
+1 !
 
Also note that if you navigate the list with the arrow keys, you'll need to provide a custom handler for focus as well, because it has the same default behaviour (which is contrary to what you want).
 
right i remember that. i just didn't want to deviate any further from the demo until the label/value change worked
 
Ah, gotcha.
 
ha!
back to normal I see
=)
 
3:23 AM
@Mark, wouldn't want to disappoint you! (;
 
@rchern meh, the only disappointing thing today was putzing around all day at work only to get swamped at 5pm when i was ready to leave
 
hate it when that happens!
 
me too
(still working )=)
 
gah!!! i just remember the question i've been wanting to ask Kevin for several days, oy.
 
lol
 
3:34 AM
when you search users on the sites, it pushes exact matches to the top/front for the various sorting options. i'm not sure you can do that with the api, but searching for users in the autocomplete is a bit sketchy.
 
3:54 AM
done.
well, mostly.
 
 
3 hours later…
6:49 AM
HI
 
 
3 hours later…
9:55 AM
Good morning.
 
 
1 hour later…
11:19 AM
Hlo
 
hello
 
11:45 AM
@balpha thanks for the heads up on the VisualHg, pretty painless
 
@NickCraver I've heard people bitching about it (compared to TortoiseSVN) -- but since I a) have never used TortoiseSVN and b) am pretty comfortable with Mercurial's commandline, I can't judge it from that perspective
 
I'm not doing branching/merging, that part may very well such, but checking in files to/from googlecode works well enough
 
The most important thing for me is that when you add/move/delete files in the project, that operation is made in the repo as well
 
12:01 PM
sorry i'm a bit slow, trying to think about the easiest way from a UI perspective for users to merge accounts on oData
 
Hello room
 
g'mornin
 
moring
 
hiee...
Gud evening
:)
 
any one help with a webview issue?
 
12:03 PM
whts that?
 
I cant get the progress bar to show if I do its always the default browser that hadles it
 
1:00 PM
var title = document.title;
setInterval(function(){
    if(title != document.title){
        title = document.title;
        // Do something
    }
}, 500);
Somehow, this doesn't work
Should title there be a global variable?
 
depends where that is
are you in another scope? possibly a document.ready handler?
 
@NickCraver Inside a callback function, yes
 
the title is scoped to that :) not global
though you should be able to access it just find inside your callback
i'm curious which callback you're in if it's an interval? are you creating overlapping intervals?
 
2:00 PM
My god... I feel like throwing my keyboard at the DOM API
Why do functions fail silently!?
That was 15 minutes wasted finding out that cloneNode's single argument is required
 
Hm, funny, indeed :-)
You'd think it would just default to false.
 
Basically, I was throwing console.log statements at a black hole
Only after doing line by line console.log could I find that it was that function's fault
 
@YiJiang which browser are you coding in?
 
@AndyE Firefox, with Firebug, using the console
 
2:19 PM
@YiJiang Hmmm... they just fixed a bug that I filed about 6 months ago where the second argument to getComputedStyle was required. It's not in other browsers. FWIW, in Firefox 4 it throws an error for me, but I've found that Firebug doesn't always display errors when they originate from the console.
Oh, and I'm not using Firebug in Firefox 4, just the built-in console.
 
Currently having fun creating plugins for CKEditor, anyone familiar with the topic?
 
@Alexander Aaahhh.. WYSIWYG editors (runs away)
 
me either
 
I'm searching for flying cars and feel sad about how it hasn't become an everyday transportation thing yet :(
 
2:24 PM
@YiJiang lol, yeah, was frustrated at first. But, their new 3.0 version is fun to work with.
All Open Source, good documentation...
 
@LucaMatteis I did the same, except for hoverboards, lots of material out there :-)
 
any know , how to generate a random number with out using native function [ Math.random]
 
@NinjaDude Is there a particular reason you don't want to use Math.random?
 
just curious to know the code
ok, where can I get the source code for native methods
 
@NinjaDude Some JavaScript engines are open source, like Google's V8. It's unlikely that you would be able to reproduce any native Math.random method in pure JS though.
 
3:17 PM
anyone have a few minutes to take a look at this bug? stackoverflow.com/questions/1843995/… I'm stuck and need to turn it in in a few hours...
 
did you mean to paste a question that is almost 2 years old?
 
shoot, wrong one
0
Q: MooTools: Parsing Ajax responseTree

JamesBrownIsDeadI have an Ajax request to an XML document. The XML document is an RSS feed. Here's my onSuccess for the request: onSuccess: function(responseTree) { // process <item> elements } How do I enumerate <item> elements and retrieve the various child values?

sorry...was looking at that old one as a reference earlier
 
babbitt -- that's the same one
 
0
Q: Mootools .get('text') not working as expected

babbittI'm taking an internet programming class and learning various javascript frameworks. I'm working on a mootools problem, and the .get('text') method does not appear to be working as expected on responseXML. Here's the responseXML: <?xml version="1.0" encoding="UTF-8"?> <users> ...

sorry...been up for quite some time trying to get this to work
 
@babbitt How does your live example work?
What should I enter in the box to get some js running.
 
3:30 PM
try the letter "e"
that results in quite a few hits
 
think it works for me
i get all the names printed in the console
 
hmm...the names aren't working for me. I'll try a different browser maybe?
 
i'm using FF 3.6.10
 
I'm using chrome 6, let me take a look at it with ff
 
yeah, curiously, in chrome doesn't work here neither
 
3:35 PM
hmmm...that's...disappointing
 
maybe try wihout mootools: see this article: clubajax.org/plain-text-vs-innertext-vs-textcontent
if you really need moo, you could try loading a non-compressed version and debug into the mootools source to see waht's wrong
 
Unfortunately, the assignment calls for me to use two frameworks. I've already completed this assignment in jquery
I've already tried tracing it through in chrome, but my javascript inexperience is killing me :)
I'll probably just complete this in firefox and then indicate to the professor that there's a bug, and file a bug report to mootools
unless anyone has another idea :)
 
the text propertie doesn't seem to be available in chrome on a xml element
well, guess that's the best idea yeah, good luck!
 
Thanks a bunch, I would have banged my head against a wall for some time before trying an alternate browser
just need to keep in mind that the frameworks claim to be portable, but that may not always be the case.
 
@Chacha102: your handiwork?
 
Yes
Mainly made with HTML5 and uses Offline Caching
 
4:10 PM
Nice
 
 
2 hours later…
5:44 PM
Hm.
So this refreshes the whole page
 
define this?
 
@rchern Isn't that always the question with JS?
 
oy.
 
6:29 PM
How do you get a full-screen fiddle? just like the one Nick Craver has on the right here...
 
@RobertMassa - just use that url format
can add whatever you want on the end
 
aha, it's the /embedded that makes this work, nice! :-)
 
yup, if you want a css tag just add ,css, etc
 
okay, nice one
 
think i found a but in chrome's JavaScript engine
hmmm
 
6:35 PM
how's that?
 
wouldn't be the 1st
 
notice that the array coming back is an array of booleans off the selector pass, and not the array of elements which is what's needed
it's not directly related, but investigating the bug in :has()
notice if you do console.dir(checkSet[0]); you get the <li> DOM node, yet if you do console.dir(checkSet); you get [false, true, true, false].
 
7:06 PM
j
hi
 
Why do such links end up in a questions about getting started in JS >_> savetosim.com/javascript
 
7:52 PM
damn
the user login/logout chat thingy on the right made me think a huge bug was on my screen
 
This is pretty slick.
Is this using some kind of comet implementation?
 
comet is a term I don't like
it's just a chat system... HTTP is not really meant for it, but if you know what you're doing is just like any other chat system (IRC and others).
 
8:13 PM
@Koobz - it's XmlHttpRequest and polling, via jQuery
 
8:24 PM
@NickCraver Cool.
 
I'm curious how many users their system can handle before the polling becomes too much
 
@Doug
@Doug Oops. That's what I was thinking. For a second I was second guessing my forays into cometd as a form of premature optimization ;)
 
@Koobz Well, I mean obviously the polling is working out alright for them currently, but it seems like most rooms only have 10s of users. So, I guess from the current load levels it would be premature optimization to try and move to some sort of push system.
I guess the real question is, how much room to expand do they have with the current system
 
well, a simple chat server can handle thousands of messages.
or even millions with very few lag
so I don't see this being much different.
 
8:41 PM
Yea, I suppose its not that different. I just can't recall seeing many chat applications running over http. This chat app seems different enough that I was just curious what their system setup is like
 
since the client needs to obey HTTP rules (it's a browser) it can't rely on sockets directly... but it can pretty much achieve the same thing by keep the HTTP request open indefinitely.
So like with sockets you usually connect() to a server and that's it... listen for socket events through select() or something.
 
That is the 'comet' approach. The downside of it is (most) web servers are running apache which isn't that good at thousands of simultaneous requests open. So you get specialized servers for it like StreamHub or Orbited.
 
sure... having apache will make a new process for each connection, which is stupid.
 
9:04 PM
if it matters, this is IIS, behind HAProxy on a VM
 
@NickCraver, really? That looks bad for performance.
don't tell me they use a DB.
 
@Luca - why? It's what the entire SO/SE site structure runs on, and yes SQL Server
don't believe stereotypes :)
 
sure, but that's not a chat system.
I'm not saying IIS because it's windows...
 
sure it is, it's http requests, get some data send some data
 
eheh, not that simple... with IIS it's hard to send/recieve data between active http processes.
i'm not even sure it's possible.
 
9:14 PM
not really, IIS7.5 isn't IIS5/6 where most of those thoughts came about
 
9:45 PM
@Hello71 Are you really 12 years old?
 
I'm 23
 
I will be 21 in two weeks.
 
happy birthday!
 
@LucaMatteis Thanks!
 
Jee, the @ is annonying... they should make it tab automatic.
like IRC clients
 
9:51 PM
@LucaMatteis I agree.
 
they like twitter >_>
 
10:08 PM
I'm gonna buy an old super nintendo and play donkey kong all night
 
@JacobRelkin Yes.
@LucaMatteis It is automatic (well tab-completing anyways)...
 
@Hello71 Wow.
 
@JacobRelkin: A 12-year-old programmer that knows about Stack Overflow is surprising to you?
 
yea sure it is, you still need the @ symbol though
night
 
10:25 PM
@Hello71 Sure is.
 

« first day (3 days earlier)      last day (4944 days later) »