« first day (83 days earlier)      last day (4848 days later) » 
00:00 - 17:0017:00 - 00:00

5:00 PM
dam, I didn't even realize that was the kittne
 
@YiJiang See it's like our child! It's mixing and repeating what we say....
@CodingKitten How are you my little one?
 
Ok, now we need 19 more code-bowling challenges...
 
@IvoWetzel ew one line
 
@CodingKitten You have to be less picky about the code we feed you
 
@YiJiang You should totally drop that, you end up with arrow style programming use the answer is that Ubuntu's support for C#
 
5:02 PM
@CodingKitten Indeed he should drop that!
 
@IvoWetzel Does your brothers suit
 
@CodingKitten I see that you are trying to splice together some of my messages - you should totally drop that and use jQuery
 
@YiJiang Well got 10 new watchers today... right now all you do is waiting for java to install some key software that and use jquery instead ;_;
 
@CodingKitten Does it what?
 
@IvoWetzel I confused here. hardly doubt that that CIW JS is fine syntactically, otherwise the rest of the mentality that it works at least three times faster than computer power. -- Saul Gorn
 
5:02 PM
@CodingKitten You're using jQuery! \o/ Good kitten
 
@YiJiang Since use {} at anytime while your 23? ..
 
@CodingKitten Don't put words in other peoples mouths
 
@IvoWetzel Problem with a CIW certificate because of you can always use ! when you know something, but it doesn't work. Practice is shocked at ?
 
@IvoWetzel Maybe filter out blockquotes too? I warned you about using :quote too much
 
@YiJiang Normally it should do that already hm.....
@CodingKitten You're broken!
 
5:04 PM
@IvoWetzel Well wrong with PERL considering every comment on his answers complains about something
 
@Chance I would think you can remove rules by function pointer or by rule id. You can always just hook into the events the validation plugin uses internally and just kick it around until it works
 
@Raynos thanks, I'll dig around and see if i cant do either of the two.. this has been a major PITA
 
Yay! I'm on the top all-time list for PHP (21, but that doesn't make sense since there's only 20 spots)
 
@ircmaxell That's just showing your points
 
Well, then I'm only 51 upvotes from 20th place
 
5:08 PM
btw: spreading the word about it over a Forrst
 
I'm 11 in the past 30 days (+118 upvotes)
 
@IvoWetzel About what, the code bowling?
 
that's because of this room.
 
@Chance you can always try to create multiple validator instances >_>
 
@Raynos I have
 
5:09 PM
@YiJiang Yes
 
@IvoWetzel Heh, I thought Forrst is more designer than developer
 
@Raynos or at least I think i am.. anytime I validate i use var validator = $(form).validate(optionset1)
unless theres another means of instantiating it that I dont know of
 
@IvoWetzel you have 14% of the JS room
 
I wish there was another js1k going on..
 
@YiJiang Yes, its mostly Design stuff, sadly but there code features still suck... and viewing an image and clicking like is easier than reading/understanding code
 
5:13 PM
@YiJiang Send me an invite
Now !
 
@ClemDesm I'm not even a professional web developer/designer. Beg @IvoWetzel for one.
 
Only 4 more +1's till a bronze for the question (It's 1 below my highest voted question)
 
I have 5 invites left.
 
@IvoWetzel Now !
 
@ClemDesm Mail?
 
5:14 PM
@IvoWetzel Only until the next month ;)
 
@Raynos Done
@ClemDesm Check you mails for cialis spam... I mean the invite
 
delete those emails
this chat is public...
 
Was waiting for you to send
Since I received it, it's deleted !
Thank you very much @IvoWetzel
 
bloddy hell... So I told you yesterday that the screen on my droid was flipping out. Well, it had stopped and was fine all last night
 
Oh, you're my friend now
 
5:18 PM
today, I plugged it in and it started again
 
@ClemDesm Yes it automatically adds the inviter to the friendlist
 
it's been doing it off and on, but always will start when I put it in the dock.
(It starts sometimes without the dock, but it always starts when I put it in the dock)
sigh. This is not going to be fun to show to the idiotos at customer-service
 
@ircmaxell too late :)
 
Sucks
in The Tavern (General) on Meta Stack Overflow Chat, 1 min ago, by mootinator
The first rule of underground voting ring is you don't talk about underground voting ring on the same site.
@IvoWetzel: I just realized mine was 2.9kb. :-D
 
0
A: Array elements vs properties?

Ivo WetzelWell, although the Array in JavaScript is an Object, there's no good reason to use the for in loop in order to iterate over it. In fact there a number of very good reasons against the use of for in on an Array. While it may seem like a good choice at first, to trade the some speed against the re...

now I want ++++++ for my copy pasta
 
5:31 PM
Wow, not bad at all
 
Still needs some fixed here and there @YiJiang do the copy-editing I'm paying your for!...
 
Not enough rep to remove a vote yet.. so I guess Ivo and Anurag get the upvote.
really a factor of up to 20x, thats crazy.
 
remove a vote?
 
@ircmaxell Click the up arrow again?
 
Well i upvoted Anurag first, before Ivo's answer
so I wanted to just give the upvote to ivo instead
 
5:39 PM
You have a time window to remove the upvote. If you wait too long you can't unless the user edits the answer
 
@Loktar Yes 20x or more, depending on the JavaScript engine obviously, newer ones get better but still it will never be anywhere near as fast as a simple for
 
Ah didn't realize i could click up again... apparently its beyond the time window now. Thanks for the tip.
 
only two ups, grml, guess people have lost interest in JS after the last couple of horrible question weeks
 
I gave you an up. But I think it's because your answer is tl;dr all the really high voted answers are like 50 characters (or so it seems anyway)
 
Pff, the other one got accepted, I'm really starting to hate SO for that
 
5:46 PM
0
Q: Efficiency of PHP arrays cast as objects?

keithjgrantFrom what I understand, PHP objects are generally much faster than arrays. How is that efficiency affected if I'm typecasting to define stdClass objects on the fly: $var = (object)array('one' => 1, 'two' => 2); If the code doing this is deeply-nested, will I be better off explicitly def...

 
I liked yours better because you mentioned how they aren't always ordered correctly. Ive given to answers and been thanked. but the dang users wont accept them, thats what frustrates me.
*2... wtf to.
 
@ircmaxell 'Don't not use' :D
 
I hate questions like that
redunculous...
re-worded
 
also what I really is the attitude to accept the fastest anwers
 
I will accept the fastest answer, only when I feel all answers are equal...
 
5:57 PM
Well it might in fact be that there are just no more people that upvote
1
A: Is there a way to avoid eval in this block of JavaScript?

Ivo WetzelThe eval here is completely pointless: // since everything in the global scope gets defined on 'window' typeof window[r] === 'undefined'; This will do the exact same thing, also note that r leaks into the global scope. // Check requirements Prototype and Scriptaculous (function () { var ...

 
I still can't get over the bastardization that the stringIsDifferent method really is
 
@ircmaxell Hope you don't have bad dreams from it...
 
It makes me want to write a The <center> cannot hold it is too late. response...
 
Well the string cannot compare :P
 
The string cannot compare it is too late. The force of regex and syntax mutalation together in the same conceptual space will destroy your mind like so much watery putty
 
6:09 PM
:D
 
@IvoWetzel +1 for copypaste
 
@Raynos yay
Soon everything will be copy pasted...
@CodingKitten And then I improve you to answer all JS questions on SO!
 
@IvoWetzel Yeah, I started an epic comment discussion
 
@CodingKitten Don't repeat me
 
@IvoWetzel Hm yes might be wrong...
 
6:13 PM
@CodingKitten Indeed
 
@IvoWetzel Well US is a barrage of the <Center> cannot hold one?
 
@CodingKitten how do I subtract two numbers in JavaScript?
 
:kitten jquery
 
Now all that's left to do is to implement subtraction via addition
 
6:17 PM
!kitten what do you think of regex?
 
Hold on a second, googling that for you... "what do you think of regex? did you mean horrible typo?" There you go!
 
:D
 
:kitten quote
 
> "[This] reminds me of a quotation from somebody that, whenever he tried to explain the logical structure of a programming language to a programmer, it was like a cat trying to explain to a fish what it feels like to be wet." - Saul Gorn
 
I like that
2
Q: Simple subtraction does not work

user558559Hi, The scipt should subtract 1 from the primary key (auftrag_id) from a table. But somehow it's not working. The variable $preauftrag_id is not getting decreased. The type of the variable is integer. I tried several subtraction-methods, but none is working. Someone have an idea? $auftrag_id = ...

See the comment chain
 
6:29 PM
Nice.
I looked at that question for a minute when it was fresh but then ran far away
 
Sigh. I hate when people mangle concepts, then argue in a post about it (that post)
 
6:47 PM
> /* higher-order bits of rand() have better entropy */
haha
 
That was one of my favorites
Only 2 more +1's to a bronze!
 
I'll add some comments to mine
(of course with bad gramma etc)
 
I like that C one...
 
7:03 PM
added comments :D
4
A: Make an application that displays text at random that conforms to the specified regex

Ivo WetzelOK, there you go... NOW quickly send me some money so I can leave this country and live on some random pacific island where I built pitfalls and hide in the jungle so I'm safe from Crockford.... // give out greeting program rand = Math.random; tims = Array() timeString = "morning ,afternoon,even...

Now I myself have to laugh xD
I really.... like it
 
I like that PLSql comment, I wish he'd write it
HA!
> // found this on another side on the internet
 
:D
obvious insider is obvious
 
hello!
 
> // == is broken so well just use regex
ROTFL
 
@ircmaxell Well I figured, I already have infinite problems with that code so...
 
7:16 PM
true
 
but its missing some html that's being parsed by regex
We need to spread the word about this, kind wait to see more broken code :D
 
Well, let's do one question every few days
And yes, spread the word!
s.unshift(cth(nc(-2)))s.unshift(s[s.length-1].replace(/(.)(.)/,"$2$1"))s.unshift(cth(nc(-32)))
 
Gonna post it on HN
> Code-Bowling, how bad code can you write?
 
> Code-Bowling, what's the worst code you can write that still works and might be found in the wild
 
> Please make title < 80 characters.
 
7:20 PM
cause it's not just about the worst code, it still needs to function and look reasonably correct...
Ok, then in that case your original may be better
 
Uh...
 
@Nathan: brilliant comment there!
 
thanks :D
 
> Code-Bowling, the worst code that still works and might be found in the wild
@Nathan +1 for the comment, indeed
 
the lack of any reference to jQuery was freaking me out
 
hmmm... I bet you could get even more horrific bowling by combining multiple js libs.
 
@Nathan: Write a JQuery version full of even more WTFery, and include in the post that this is a better way than @Ivo's
 
0
Q: how to getElementsByName() with context other than document?

testerI am unable to search for nodes with a specific name with any other context than document. is there a cross browser way to search getElementsByName() with a context other than document.getElementsByName()?

facepalm
> // pull in prototype jQuieris XYZ is slow
 
I'll wait a day or two and add a bounty
 
wonders if he could do it entirely with copy-n-paste from w3schools
 
7:26 PM
oh god
:kitten quote
 
> "Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live." - Martin Golding
 
HAHAHAHAHAHAHHAA
 
in that care we're as good as dead
 
Talk about a relevant quote
 
we need at least one perl version
 
7:27 PM
And one python version, and one Lisp version, etc...
Ohhh, idea!
 
... usually I am in fact the guy who ends up maintaining my code. WHAT ARE YOU IMPLYING!!! I KNOW WHERE YOU LIVE!!!!!!
 
> PHP is a minor evil perpetrated and created by incompetent amateurs, whereas Perl is a great and insidious evil, perpetrated by skilled but perverted professionals. - Jon Ribbens
 
>++++++++++[>+++++++>+++++++++++>+++++++++++>++++++++++>+++>++++++++>++++++++++>+++++++++++>+++++++++++>+++++++++++>++++++++++>++++++++++><<<<<<<<<<<<<-]>+>+>+>>++>--->+>++++>>----->>+++><<<<<<<<<<<<<>.>.>.>.>.>.>.>.>.>.>.> <- My entry
 
@ircmaxell Can you give that the shape of a bowling ball?
 
I'm going to try my hardest
 
7:29 PM
Still it has to be WTF
hm
I want to write more WTF code... :(
That's so fun
 
It's a bit off, but here:
                 >+++
         +++++++[>+++++++>+++
    ++++++++>   +++++++++++>++++++
 ++++>+++>++++++++>+++++++++++>+++++
++++++>+++    ++++++++>+++++++++++>++
+++++++++>++++++   ++++><<<<<<<<<<<<<
 -]>+>+>+>>++>--->+>++++>>----->>+++
    ><<<<<<<<<<<<<>.>.>.>.>.>.>.>
              .>.>.>.>
 
looks more like.... a leaf?
or something... else
 
It looks like a spade
 
kinda oniony
 
yeah, skipping it
Submit it to /. LOL...
You want me to UT my fubar code too?
$this->assertRandom(Random::getRandomSeed())... hehehe
 
7:48 PM
:D
 
0
Q: How to most efficiently check if two strings are different?

Click UpvoteI have two very large strings. How can I compare them to tell if they're identical, or if one of them is different than the other? (That way I can leave the identical strings alone and process the ones that have changed).

another WTF worthy post...
 
missing rep
 
It's up on the highest voted question for the past 2 days
And it's 26 views away from being on the most viewed list
 
0
A: Determine bounds of shape / graphics drawn into a Canvas

LoktarI assume you are using LineTo's the only way I could think of would be to keep a min/max stored for the height and width as the user is drawing paths. Other than that the only way to pull back info from the canvas would be to use getImageData which will only give you raw pixel information. Quick...

 
What's sad is that even with a +8 question, +6 +4 and 2 +1 answers I'm still a ways from repcap
 
7:54 PM
I really love jsfiddle
 
And on XKCD
is trying to get the following badges with this question: Announcer, Booster, Benefactor, Good Question, Notable Question, Popular Question, Promoter, Publicist, Self-Learner, Taxonomist...
 
Hi!
Try to guess how to pass this test, without checking the code!!! (the timer starts when the input field gets focused)
 
8:06 PM
Time's up?
I did type something there tho
literally, something
 
time is 5 sec.
the key is in the description
 
lol nice
got it 2nd try
 
I typed in "QUICK!!!"
 
@Na7coldwater Yes, that's the key!
 
First try was just random letters.
 
8:09 PM
first try was "in something in the input field below"
but i couldnt get that far, before time ran out
 
Could anyone link me the site where I can check the source of specific jQuery functions?
 
You mean within the jquery source itself?
 
I just bookmarked the source URL (code.jquery.com/jquery-1.4.4.js)
 
0
Q: Comparing array to var during iteration(cont.)

MekeSo here's my problem.. Might just be tired but, I want counter to ++ only if number has not occurred in array. Meaning during the 4 iterations, counter should ++ only on iteration 1,3,4 var array = [], number, temp = [4,2,5,9], counter = 0; for(var i = 0; i <= 3; i += 1) { array.push(i);...

WTF?
 
yeah...
im looking at that too
i dont really know what he means totally.
Im assuming he wants to fill numerical gaps in the array
or count valid numbers in it.. idk, skipped over it
 
8:19 PM
nice
I just answered a question by looking at PHP's source code...
ZEND_API int zend_binary_strcmp(const char *s1, uint len1, const char *s2, uint len2) /* {{{ */
{
	int retval;

	retval = memcmp(s1, s2, MIN(len1, len2));
	if (!retval) {
		return (len1 - len2);
	} else {
		return retval;
	}
}
Up to over 280 views already...
 
is leaving for a hour
 
Take it easy
I had to have hit the Announcer bade already. When will I get higher is a good question...
 
If you're using jQuery, the easiest way to loop through an array is:
$(myArr).each(function() {
  alert(this);
});
And I've just noticed that you don't need to use this[i], unlike in for and for in loops.
set status to away
 
But that's no looping over an array, is it
there's a scope change, so it's mapping an array to a function
 
it does the same thing, doesn't it?
 
8:27 PM
in your trivial case, yes
but since the scope is changed, local variables can't be accessed, exception bubbling will be different, etc...
0
Q: How to most efficiently check if two strings are different?

Click UpvoteI have two very large strings. How can I compare them to tell if they're identical, or if one of them is different than the other? (That way I can leave the identical strings alone and process the ones that have changed).

Why was that answer accepted? It's SO I know, but still..
 
Lol i honestly assumed that was a joke
a wrapper class to compare if a string is different??
 
Yup
== is at worst case twice as efficient as hashing and comparing hashes (ignoring the complexity of the hash function)...
 
meh oh well i upvoted yours. Looks like one of the SO questions youd see on reddit where everone laughs.
 
@ircmaxell Well, it depends on what "very large" means. If they're talking about a gigabyte of data, I can imagine that someone not intimately familiar with how PHP does string comparisons is looking for something that will not process each byte, but handles things somewhat intelligently
 
@ircmaxell LOL how do you placed in that upvote image? :D
 
8:35 PM
@kander: But if that gigabyte is already in memory, == will be fastest always...
 
@Nyuszika7H if you copy a link in here from so, it automatically does it
 
Yay! We hit +10 on the Code-Bowling question!
 
Of course :) I'm not saying that == would not be most efficient... but I can understand how someone might feel they need to look for something bette
 
I didn't understand why should I use == sometimes in MS-DOS until I learned that in JavaScript.
 
idk.. it seems like crazy overkill for a string comparison regardless.
 
8:37 PM
I know, just venting on the lack of information and the answer that assumes a lot outside of what's provided is accepted, where the one that directly answers the info provided is not... Typical I know, but still
 
I hate the fact that he wrote 'very large'... that tells us nothing.
it could be like "These strings hold the user's WHOLE ADDRESS! not just their street name!"
it's like he is trying to dumb down the question so that people will be able to understand it...
 
Or it could be a string generated by base64_encoding the entire HDD
 
ahahaha
it's funny till you realise some people might actually do that :(
i can only hope that if they do
they use jquery
 
If you're not measuring the size of the string in multiple libraries of congress, it's not big...
> Thus one might claim that the entire Library of Congress could be packed onto a single 2.2 terabyte storage unit — excluding the pictures.
 
9:11 PM
@Raynos: This reminded me of you with all your talk about clone: verydemotivational.memebase.com/2011/01/07/…
 
9:26 PM
17
Q: Which one will execute faster, if(flag==0) or if(0==flag)?

mr_eclairInterview question: Which one will execute faster, if(flag==0) or if(0==flag)? Why? Can anyone tell me with a example?

Quite interesting. Note the C++ part, it's important...
 
Hi!
set status to available
@ircmaxell Actually, in JS, '1' == 1 takes 1 ms, but 1 == '1' takes 4 ms.
 
@Nyuszika7H What browser?
 
@Na7coldwater Chrome. If I make 5000 iterations, the first takes 8 ms, and the second takes 7 ms.
 
@Nyuszika7H Maybe it's faster to convert from a string to a number than a number to a string, or vice versa.
 
var flag = 0;
console.time('flag == 0 (x5000)');
for (var i = 0; i < 5000; i++) {
  flag == 0;
}
console.timeEnd('flag == 0 (x5000)');

console.time('0 == flag (x5000)');
for (var i = 0; i < 5000; i++) {
  0 == flag;
}
console.timeEnd('0 == flag (x5000)');

Output:
flag == 0 (x5000): 9ms
0 == flag (x5000): 12ms
 
9:43 PM
I'm changing the CSS that's loaded like this: document.getElementById("myLinkElement").src="newSrc.css"; but it isn't having any effect in IE .... any ideas?
 
Remove the current link element and add another one with the right src.
 
@Greg document.getElementById("myLinkElement").setAttribute("src", "newSrc.css") maybe?
 
@Greg why would you do it that way instead of having all your styles loaded and just changing the class?
 
@Nathan just experimenting ...
 
@Greg With link elements, I believe you need to remove the old element and add a new one. This is certainly true for favicons; it may be true for stylesheets too.
 
9:49 PM
@lonesomeday cool ok
 
 
1 hour later…
10:58 PM
That's interesting @Nyuszika7H...
 
11:24 PM
how do I properly clear these floated li a elements? jsfiddle.net/X8nu8/1
 
Up to 624 views...
I hate Bing, I hate BestBuy
 
@Greg I think you want clear:left on the ul?
 
@Nathan not sure that does anything?
 
nope
@Greg, how about header h1 { padding-bottom: 1em; }
or maybe margin-bottom is more correctlier.
 
11:57 PM
hi kids
 
00:00 - 17:0017:00 - 00:00

« first day (83 days earlier)      last day (4848 days later) »