« first day (850 days earlier)      last day (4090 days later) » 

9:00 AM
Sure it will
 
It is valid syntax, and its behavior is defined. Unary plus, then addition
 
@dystroy just want to know if that is how people write the same code
 
sam
Hi guys, i need help parsing through xml using javascript
 
"">+(+"1")
 
sam
my rss is located at dribbble.com/tags/3d.rss
 
9:00 AM
!!> +(+"1")
 
@JanDvorak Maximum execution time exceeded
 
sam
this is how i get the title but i need to get the image src
myitems.item(i).getElementsByTagName("title").item(0).text
 
@JanDvorak sick, thx
 
...gadawm
!!> 4
 
+x alone is sufficient to turn it into a number
 
9:02 AM
@Zirak 4
 
!!> +(+'4')
 
@Zirak 4
 
!!> +'4'
 
!!> +(+"1")
 
`4`
:7675664 `1`
 
9:02 AM
crap
+(+"1") works
sorry about that guyz
 
I prefer using `Number`, though:
!!> Number( '1' )
 
Seriously, can we do something for this question full of terrible answers ?
 
@Zirak 1
 
1
Q: What's the name of this webdesign element/trick?

PaulSurfing the web I see websites with a floating design element. But I cannot find how it is called. Does somebody know the name of the following element: At the adobe website there is a yellow box with the question "Was this helpful?". When you scroll down it stays at the top of the screen. http:...

 
9:04 AM
Add a good answer
In it, condemn the bad answers
 
actually +"1" works, cause it's unary operator right?
 
6 mins ago, by Zirak
yeah, it's the unary +
 
yeah
thx bro
 
Enbroy
 
what does that mean?
 
9:07 AM
!!/google enbroy
 
!!/define enbroy
 
Could not find definition for enbroy. Trying Urban Dictionary
@JanDvorak Y U NO MAEK SENSE!!!???!!?11 No results for enbroy
 
Enjoy turned awesome, with the conversion of "jo" to "bro": Enjoy => Enbroy
 
9:11 AM
oh
 
It's the latest hot thing
 
@Zirak I had a thought - can you implement google fight into the bot?
 
9:27 AM
Google fight?
 
0
Q: Required a Certain File Needed to Convert iOS to Android Compatible Game App

David DimalantaBefore making a fully functional gaming app that makes compatible between iOS and Android, I would like to ask a question. For converting into an Android compatible app and vice versa, should you think an HTML file and a Javascript file associate with a PhoneGap engine will needed in order to con...

 
!!/stat
 
@JanDvorak Jan Dvorak has 9260 reputation, earned 0 rep today, asked 0 questions, gave 435 answers, for a q:a ratio of H̸̡̪̯ͨ͊̽̅̾̎Ȩ̬̩̾͛ͪ̈́̀́͘ ̶̧̨̱̹̭̯ͧ̾ͬC̷̙̲̝͖ͭ̏ͥͮ͟Oͮ͏̮̪̝͍M̲̖͊̒ͪͩͬ̚̚͜Ȇ̴̟̟͙̞ͩ͌͝S̨̥̫͎̭ͯ̿̔̀ͅ.
 
@Zirak is that intentional?
 
9:36 AM
ermmm
 
@SOChatBot wat!?
 
@phenomnomnominal would you have a couple of minutes to see if you can help me resolve the display issues I am having with gobet.ergonomiq.net/divorce-séparation/…
 
@alisamii, don't ping people randomly, it's quite rude.
 
!!/tell octavian google bobince html regex
 
9:40 AM
sorry
 
And no, I'm busy
 
OK...np.
 
@phenomnomnominal this one is good: googlefight.com/…
 
hello, I am new to prototype based programming in JS, and was confused how to create a constructor in JS ie. inside a function. I have read in blogs that we don't need to create anything explicitly instead when we instantiate the class, everything inside the function will execute, and thus will behave like a constructor. Can anyone guide if I have understand this concept in a wrong way?
 
9:42 AM
@phenomnomnominal just try your native language instead, it's not right because in danish satan=satan, and god=gud ;-)
But I really like that the world is kicking the universe' ass :P
 
Haha yeah!
 
When you have a change event handler bound to a checkbox with jquery, how can you simply prevent the click event to bubble up the dom ? Do you have to bind the click event instead or is there a cleaner way ?
 
Yeah, I think you'll have to listen to click.
 
But then you have to have 2 handlers or to change the value of the cb yourself, right ?
 
The change event is only the result of the click event not being prevented-default IFAIK
 
9:51 AM
OK, I found a solution to handle properly my many widgets : I added a stopPropagation event handler just to the immediate parents of my widgets. It stops the propagation without messing the widgets.
thanks
 
> Chuck Norris once worked as a weatherman for the San Diego evening news. Every night he would make the same forecast: Partly cloudy with a 75% chance of Pain.
 
Is jQuery.each() still slow? stackoverflow.com/questions/1883611/should-i-use-jquery-each has answers from 2009.
 
jquery is still slow
 
Oh yeah, going native wherever possible based on cross-browser compatibility. I wondered whether there was any more up to date evidence on .each() in particular.
 
But it's hard to be bitten by jquery slowness, really. All my pages are 100% js generated and never had I had problems with jquery slowness.
It's slow as in "1 ms instead of 100ns"
 
9:57 AM
more like "1ms instead of 350ns"
 
@dystroy Yeah, in most circumstances, the difference between perceivably slow to a human and merely slower, makes readability, maintainability and portability a fair trade for nanoseconds of performance.
 
@Yoda what do you need your class for?
 
o/
 
Yes. When you're server side, you don't want an operation to take 10 ms when it could be done in 1 ms. But client side, as long as you don't have dozens of them when you click, it doesn't matter.
 
Of course, there is nothing bad about using native loops directly either.
 
10:00 AM
@dystroy exactly, client side code does not have to be optimized most of the time
 
isn't that like... kind of eval ? label.setAttribute('onclick', 'alert("' + i + '")');
 
using addEventHandler("click", vs using $().click does not matter
@Glutamat yes it is, also, avoid it
 
It is eval. Who recommends that - may we downvote him?
 
1
A: get selected value in label using JavaScript dynamically

Chris ShepherdNot at all clear from your question description what it is you need. If what you're wanting is to dynamically create labels, and have access to their onclick events; have a look at the Javascript functions appendChild and setAttribute. I've created a JSfiddle which demonstrates what you might n...

 
Yes, let's downvote !
 
10:02 AM
Yay! Downvoting!
 
+1/-3 and counting
 
lol, poor guy. It's his fault for giving an extremely bad answer
 
0
Q: Recursive Function for create Menu Tree from Database in Asp.NET & C# website

user22051In My Asp.NET website I want to Create tree structured Menu from Database .

 
It can't be deleted either, because of the green checkmark
 
Someone here can give a good answer, and we could suggest OP accepts it instead
 
10:04 AM
Man i always feel sad for the people i downvote
is this fair enough ? jsfiddle.net/WLKm8
 
Why? I only downvote once for every 10 times I upvote, usually I have a good reason and usually it is that the questions is very poor or the answer is very bad.
 
@BenjaminGruenbaum I would like but I try to make sense from the question...
What's a selected label ?
 
@Glutamat I don't like it, I would assign a different event to each label not delegate it
 
I don't know, I didn't really got his question
Ok, you wanna post an answer or should i post a modified one?
 
All he needs to do is change label.setAttribute('onclick', 'alert("' + i + '")'); to label.addEventListener('click', alert.bind(window,i));
 
10:08 AM
Is editing his answer appropriate ?
 
Yes, it is, though in that way he gets more community approval
 
I'd wait for the OP to fix it
 
Ok
 
I've never used the multiple-argument version of bind
!!/google mdn bind
 
@JanDvorak it's AWESOME
 
Is there a way to curry without binding this?
 
@JanDvorak no :(
 
Ok, time to remove the downvotes !
 
Should I extend Function.prototype to make one?
 
Did i get this right that if you use the multiple arguments bind, the other arguments passed to the function get appended to the argument list ? so the bound arguments are preserved ?
 
10:11 AM
What if OP needs IE7 support? I don't think IE7 has addEVentListener?
 
@JanDvorak no you should not, you should elevate a function instead (something similar to what jQuery do with DOM elements when they want to add methods to them)
 
You mean, wrap it in a different object?
 
function elev(fn){
    return{
      curry:function(){
    };
}
...
this way you could do
elev(alert).curry("Hello World");
Instead of alert.curry("Hello World")
you wouldn't change the original function prototype, which is problematic if you're working with external libraries
 
I thought external libraries only expected Object.prototype to not be extended, and the reason was a potential namespace clash with future versions of ES
 
10:18 AM
@JanDvorak you should not change any native objects with the exception of shimming it is considered bad mannered :P
 
hi to can any body help me how to find the given string is exist or not in an array
 
@naveen indexOf
 
@naveen arrayName.indexOf("myString") !== -1
 
this is my code $.each(glob,function(key,value){
//$.each(value,function(key,value){alert(value)
//alert(knownstring)
var playerClass = value['username'].match(new RegExp("^" + knownstring + ":\d+$"));
})
 
!!/tell naveen google mdn array indexOf javascript
 
there is a problem of indexOf() in IE
 
Fuck IE
 
@naveen yeah, you'll have to shim indexOf if you are to support oldIE
 
here my problem if i enter the "SE" in text box then all the SE related names should be displayed
 
10:22 AM
Then you want a 2d search? That is, filter array elements where indexOf(key)>-1?
 
here this is my json data. [{"username":"naveenvoru","avatar":null},{"username":"testnaveen","avatar":null},{"username":"juliecorsi","avatar":null},{"username":"davidrichman","avatar":null},{"username":"brandonwalker","avatar":null},{"username":"katekruse","avatar":null},{"username":"marjorieking","avatar":null},{"username":"eldonflanagan","avatar":null},{"username":"andreasberry","avatar":null},{"username":"mariaconner","avatar":null},{"username":"claudewhitehead","avatar":null},{"username":"jacobbuck","avatar":null},{"username":"brianweatherholt","avatar":null},{"username":"susansmith","a
 
[<YOUR ARRAY>].filter(function(elem){return elem.charAt(0)==="N"})[0];
 
Alternatively, loop manually with for
 
In javascript, can you get the setter function of a property ?
 
the function itself?
like __lookupSetter __ ?
 
10:36 AM
Object.getOwnPropertyDescriptor gets you the descriptors of a property including getters and setters
 
@Glutamat are you sure?
 
oh yeah, for a specific property it does that, cool
 
Yes it does =) Its quite practicable some times
 
@SOChatBot hello
 
11:17 AM
!!/chuck
 
@JanDvorak Command chuck does not exist.
 
!!/help
 
!!/norris
 
@JanDvorak There?s an order to the universe: space, time, Chuck Norris.... Just kidding, Chuck Norris is first.
 
11:27 AM
posted on February 12, 2013 by Joseph the Dreamer

So this is the "main" for my calculator app in JS. It works like your everyday pocket calculator. Although it works, I think I'm using the wrong procedure in using stacks for a calculator. Also, the …

 
@Feeds why are you posting 404s?
 
dammit, now i have to listen to this "Harlem Shake" over and over
@JanDvorak "This question was voluntarily removed by its author."
 
@Feeds test
oh it doesn't work
 
11:49 AM
@JanDvorak You can probably do it, if it's just a simple link
@JanDvorak I'll let you answer that question
 
Hey room! :)
Are jQuery discussions welcome here?
 
sure
 
yeah
uh huh
 
offtopic discussions are welcome here as well :-)
 
:)
I wanted to create draggable widgets like iGoogle used to have. Here is a demo of something similar: nettuts.s3.amazonaws.com/127_iNETTUTS/demo/index.html
 
11:52 AM
oh, @JanDvorak, about Azorubine: Only in a solution are the Na cations present. As solids, they're in the main crystal, so there is a bond.
 
I have a basic system coded, but one thing baffles me, how the droppable slot takes the exact dimensions of the draggable when the draggable is hovering
 
Also, in case you were wondering, the overly-connected sulfur is part of a Sulfuric acid derivative
 
That example uses old customised jQuery code, which I do not want to take
 
@SubhamoySengupta I guess there's a hover or overlap event or something in that flavor
 
yes, you can add a class to the droppable upon hover event
but every draggable has different height
so I am confused how the droppable is taking the height of that particular draggable upon hovering
 
11:55 AM
!!/google jquery-ui droppable
 
haha of course I have looked there. But there is no example I can see where droppable adapts draggable's shape
 
@SubhamoySengupta gridster.net maybe check this one out
otherwise have a look into draggable, droppable, grid API of jquery ui
 
Thanks guys. I have already been through the droppable API though...
I will give it another go :)
 
12:04 PM
@SubhamoySengupta I'm pointing you to the exact event you need. Also see the out/dragout event.
Something like $(target).on('dropover', function(e){this.animate('height', e.draggable.height()+10)})
alternatively, create a drop-area inside the droppable on dropover and animate its height. On dropout, animate the height back to zero, then remove the element.
 
Hi
Can i customize the toolbar that appears in html5 video tag ?
/Hide it
 
I think it's possible... haven't checked, though
 
12:21 PM
@JanDvorak Yes yes I know but I was wondering why our bot would spit that out on a normal number.
 
Amaan no. Just shady ISP and if the page loses connection someone has to physically reload the page.
I will move to home PC today
 
You'll move what? The bot?
 
Yea
 
Need help with that buddy? He's a big fucker.
 
by move I mean log in at him and turn off the monitor
 
12:23 PM
:D
Oh yea Bob, thanks for making my keyboard all sticky with your juice ...
Had to wash that keyboard in the sink and dry it!
 
@OctavianDamiean well, he spit that out on a division by zero
 
@OctavianDamiean Is your keyboard fine now ?
 
Since my questions are none, my answer-to-question ratio is infinite
 
@dystroy Yea, all clean now. :)
 
!!/stat JanDvorak
 
12:28 PM
@JanDvorak Yea, let's call it like that.
 
@dystroy Jan Dvorak has 9260 reputation, earned 0 rep today, asked 0 questions, gave 435 answers, for a q:a ratio of H̸̡̪̯ͨ͊̽̅̾̎Ȩ̬̩̾͛ͪ̈́̀́͘ ̶̧̨̱̹̭̯ͧ̾ͬC̷̙̲̝͖ͭ̏ͥͮ͟Oͮ͏̮̪̝͍M̲̖͊̒ͪͩͬ̚̚͜Ȇ̴̟̟͙̞ͩ͌͝S̨̥̫͎̭ͯ̿̔̀ͅ.
 
well... fine...
 
64 messages moved to bin
Whooosh!

Sandbox

Where you can play with regular chat features (except flagging...
For messing around with the bot.
 
@JanDvorak That's all your fault. You should ask questions too. SO is about outsourcing your work to bored engineers of other companies, you know ?
 
!!/stat dystroy
 
12:37 PM
@JanDvorak Maximum execution time exceeded
 
I ask many questions
 
@dystroy I'm on the other side of the fence. I'm one of those bored engineers. :D
 
@JanDvorak dystroy has 52791 reputation, earned 135 rep today, asked 27 questions, gave 2242 answers, for a q:a ratio of 27:2242.
 
"wat" ?
At least my q:a ratio is rationnal
 
12:39 PM
!!/tell dystroy urban wat
 
which is the first thing you expect from a ratio
 
@dystroy wat The only proper response to something that makes absolutely no sense.
 
I like that definition.
 
@dystroy pi^2/pi is not rational (no LaTeX around these corners :-( )
 
@SOChatBot I know what wat means. I wanted to know why wat was to be used there ?
 
12:41 PM
@dystroy Cause you've pinged me initially and then edited the message. :D
Got me all confused.
 
F*** There's no entry for ratio in French wikipedia...
 
Try the english one
 
Wonders what'll happen.
 
I don't like the English one. I was looking (totally unfair I know) for one specifying that the common meaning of a ratio involved integers. No luck with Italiano, French or Deutch too.
 
!!> Math.pow(Math.PI, 2)/Math.PI === Math.PI
 
12:44 PM
@OctavianDamiean true
 
NO WAI!
 
For numbers, === isn't binary strict equality
 
!!> 0.1+0.2 === 0.3
 
@JanDvorak false
 
it is
 
12:44 PM
no
 
What is it then?
 
!!> Math.pow(0.1, 10)
 
I wonder where I saw an epsilon test in the norm...
 
@OctavianDamiean Maximum execution time exceeded
 
12:46 PM
@OctavianDamiean That I believe.. when you're dealing with powers of 2
 
Oh come on bot ...
 
@OctavianDamiean 1.0000000000000011e-10
 
hello guys....
I new blogging ..
i have made a blog with a number of post
the thing if i type the title of one of my post in google , it links me to my blog instead of my post that contains the title
 
Congratulations ?
 
how to link directly to my post....???
help plz
 
12:49 PM
@CodeJack Call 101-Google
 
There's not enough information to answer
 
Meh, 0.1 to the power to 2 would have been enough actually ... whatever, you get the point.
@Neil O rly!? :D
 
!!> (0.1*0.1)/0.1 === 0.1
 
@JanDvorak false
 
nods
JavaScript isn't really the language for mathematical problems, but that's nothing new. :D
teehee
 

« first day (850 days earlier)      last day (4090 days later) »