« first day (1521 days earlier)      last day (3419 days later) » 

12:14 AM
We'll need to see some code to tell you what's wrong
 
var reader = new FileReader();
reader.addEventListener("loadend", function(){
var outputArray = reader.result;
console.log(outputArray)
});
reader.readAsArrayBuffer(blob);
 
If you tried load instead of loadend, I don't know
I had problems with Buffers in the browser before, but can't remember what it was
 
12:30 AM
Where is the value of blob coming from?
Or is that a baked-in parameter?
 
!!> var blob = new Blob([new Uint32Array(10)]); var reader = new FileReader();reader.addEventListener("loadend", function(){var outputArray = reader.result;console.log(outputArray.byteLength)}); reader.readAsArrayBuffer(blob);
 
@copy "ReferenceError: FileReader is not defined"
 
Anyway, it works for me
 
12:59 AM
Your example works for me too
I changed my code to print the byteLength, and it appears to print a correct value
Maybe the data is being read in correctly, but the array just isn't printing for some reason
 
1:45 AM
hello everyone
 
hello this.Tony
 
@phenomnomnominal can you help me with is question
1
Q: How to automatically show select for crop on image

this.TonyI was wondering how can I make imgareaselect select automactically once photo file is selected? so that the user knows that they can crop on what to use in a photo so far I have: What I'm trying to achieve is when I select an image file I'm trying to make imgareaselect select a part of the photo...

 
@this.Tony not right now sorry
 
thanks anyway
 
Can I ask a jQuery queiiton in here?
gah, question
 
1:54 AM
@Hybridwebdev can you help me out
?
 
@this.Tony Might be a little above my head I'm afraid, I've never attempted something like that
 
thanks anyway shoot your question i might be able to help
 
Let me through it in a bucket
so what I wanna do, is be able to append a value to optional
// On click, we should append $(this).attr('Title') to the optional object, and then pass it to the ajaxSubmit;
// the issue I'm having is, within the optional object, the value is undefined;
 
Array.sort isn't stable, but is it deterministic?
 
Check the spec
 
2:02 AM
essentially I am trying to re-use the optional for several different ajax calls in different places, figure I should be able to add to the object and reference it within, but damned if I can figure out how
 
@Hybridwebdev why does optional have all that data?
@Hybridwebdev why not make it a function?
@copy can you help me out with question stackoverflow.com/questions/27261671/…
 
they are just callback functions
 
no
 
@copy no?
 
user2490157
hes talking to tony
 
2:05 AM
@DaemonOfTheWest Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
DaemonOfTheWest is the only one who understands me
 
this should be a relatively simple question, Im unsure why no one has an answer
 
user2490157
to be honest I have no idea what you asked there
 
...
how do you add a variable to a jquery object
 
user2490157
maybe it's because people don't want to dig through complicated custom code to try to understand it
 
2:12 AM
....50 lines is complicated?
stuff that, less than 25 lines if you remove empty lines
 
user2490157
it LOOKS complicated. And looks can go a long way (pun intended)
 
user2490157
what exactly do you want - in plain words.
 
wow, if you think that code looks complicated either a) You didnt bother to look at it or b) You really dont belong in a JS chat room, unless all you're doing is ASKING for help
 
user2490157
odyneic.net is not loading.
 
user2490157
(so I still have no idea what imgareaselect does)
 
2:16 AM
@DaemonOfTheWest that was my question he had a different questionn
 
user2490157
oh oops!
 
lol
 
user2490157
where is Hybrid's question then?
 
really wish they'd ban time-wasting trolls from these chat rooms. It's nice to have a place to find help, but people chiming in their 2 cents when they have nothing useful to contribute is just annoying
 
user2490157
someone is merry today.
 
2:18 AM
@Hybridwebdev Calm down or I'll calm you down
 
your question is beyond my scope @Hybridwebdev
 
@copy Uhm, he's trolling me dude...
@copy dont appreciate people wasting my time..
 
He is very clearly not
 
@Hybridwebdev just re explain your question
to them
 
I'll just keep googling
 
user2490157
2:22 AM
I still don't know what you're asking for. Is it a stackoverflow question? If so, post the link instead of complaining to someone who just joined the chatroom (who doesn't know whats going on) and accusing him of being a troll.
 
user2490157
@this.Tony is this what you are asking about? stackoverflow.com/questions/15346192/…
 
2:46 AM
@DaemonOfTheWest this is what i asked stackoverflow.com/questions/27261671/…
@DaemonOfTheWest nvm you pointed me to the right direction
 
 
1 hour later…
4:14 AM
Fuckin' vendor prefixes!
 
4:50 AM
The hats are back! Yayy!
 
5:00 AM
@RahulDesai are you a javascript expert?
 
@bushdiver Not as much, but I try my best in answering Javascript queries.
:)
 
If you're interested I can paypal you?
 
the test only takes like 3 minutes.. i just keep getting them wrong and the questions are timed grr
 
 
5:06 AM
@bushdiver looks like you need to practice more.
This is sick!
 
@RahulDesai does that mean you'd rather not help? I can send paypal to your email as payment. If you helped id be soo happy =D
 
@bushdiver We're not here to help you cheat on tests.
 
Folks, is there a known issue with using fadeOut() doesn''t work elements that are styled with display: table-row;.
It's a faux table made with divs (as described here).
 
Sim
quick question can multiple embed posts from facebook searched via javascript below is sample of embed post
 
5:29 AM
@RahulDesai Holy shit, I've been to that cafe!
@Sim Please don't code dump in here. If the question is more than a few lines long then please use pastebin or put together a jsFiddle
1 message moved to Trash can
 
@monners its so awful
I mean the situation
 
Was gonna say, the chocolate ain't that bad
 
Sim
@monners embed post doesn't work on fiddle neither codepen just tried it
 
Well then it sure ain't gonna work in here
 
Sim
are you going to be able to answer my question though?
 
5:35 AM
I don't have time to, personally. Put together a fiddle and if anyone's interested they'll attempt to help you
 
Sim
thanks
 
5:58 AM
Hi
{"key1": "val}ue'1", "key2": "val,ue2" ,"id":"val ue3$","key6": 121, "id": '$val:ue4$$', "key5":"" }
^ How to get only values from the above string?
I can't convert it to object as it is not in valid JSON format
 
Try escaping the presiding }
 
I tried this regexr.com/3a2ut
 
inside the value
I think thats causing the problem
 
ohh ok
I think that is not the issue. still I am seeing error if I use JSON.parse. anyway I am trying with regex
and I am very close to the solution
Any help?
 
@Loktar You're like this with games: en.wiktionary.org/wiki/%E7%A9%8D%E3%82%93%E8%AA%AD
 
6:06 AM
I get close something more.. regexr.com/3a2v3
 
lol
 
@Mr_Green didnt tried $.each() ?
 
@JanakaRRajapaksha I didn't get you?
 
@Mr_Green something like this? jsfiddle.net/p7ozu7z5/1
 
@JanakaRRajapaksha it is showing "Property" names not "values"
 
6:20 AM
yeah get the value of property
 
BTW, I can't see property id in alert.
it seems to be not showing duplicate property names
 
@Mr_Green it is not id?
 
1 min ago, by Mr_Green
it seems to be not showing duplicate property names
 
@Mr_Green do i need to fix every step for you?, i gave you a way to get values foreach property, fix it to be match to your requirements
 
$.each(j, function(i){
    console.log(j[i]);
});
 
6:32 AM
@Loktar yeah I got it.. but my senior dev said not to use any existence plugins and do with regex. so didn't reply.
anyway thanks to both of you
 
existing plughins?
like jquery?
You can do all that with purejs easily fyi
 
ohh yeah facepalm
 
hello everyone!
 
7:10 AM
What should be the regex for any \W which is not ,
 
@argentum47 eh?
 
Btw, what happened to 12 days? lemon's gh repo hasn't actually seen any updates, nor has the gist, and there's no starred message. Is it on? If so, is it "private" ?
 
hi guys
 
@user2736704 Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
@CapricaSix ok thanks
 
7:24 AM
Who the hell keeps starring random crap?
 
what!
 
eh?
 
eh? means what :D
 
what?
 
7:39 AM
I am using laravel 4.2
$.ajax({
type: 'post',
url: 'http://localhost:81/larvel_exmp/public/users/'+this.value,

success: function($data)
{
$('span').html($data);
}
});
Route::get('users/{username}',function($username){
return $username;
});
Can't get back any error or data
instead If I use the resource routing for another controller then that works fine.
Any Idea please??
 
yeeehh
 
hi guys
i have one question
 
how do I properly check for undefined in javascript?
is undefined a string literal?
lets say I've var myvar; and i want to check for myvar as undefined.
 
7:53 AM
ok
 
@Java_User typeof myvar === "undefined"
 
Mornin'
@Java_User:

if(myVar){
// Do stuff`
}

(This only works if `myvar` is declared)
 
myvar === undefined can work as well though
 
!!> typeof myvar
 
@Kippie "undefined"
 
8:03 AM
!!> myvar && 1
 
@Cerbrus "ReferenceError: myvar is not defined"
 
^ that's why you may need to use typeof
 
can hacker modify javascript before document ready
e.g. change values of variables
 
Yup
 
8:10 AM
Download js, edit js, load page with own js
 
would it go to same server though
 
depends on the hack
Anything is possible, as long as you believe!
 
maybe this
5
Q: Running a function just before $(document).ready() triggers

RaynosI've attached multiple functions in multiple files to $(document).ready and would like to attach a single function to happen before them as either the first that $(document).ready handles or to independently trigger before the $(document).ready handler. Is there any way to handle the order of fu...

 
oh my var
 
Thanks guys for the replies
 
8:25 AM
26k user answers a "How do I filter an array by it's objects properties?" question instead of cv-ing it as a duplicate...
2
A: Return certain keys from an array

JLRisheWhen you want to select only items that match a certain condition from an array, the method to use is .filter(): var cityCode1 = resellerList.filter(function (x) { return x.fCityCode === 1; }); This will produce an array of objects where fCityCode is 1.

Damnit...
 
hi all
is it possible to integrate a "google-map" object in a html "canvas" element? google map never appears in mine... :/
 
Doesn't look like it, on first glance, @Julo0sS.
You could place a canvas on top of the map div, though.
 
user2985029
@Cerbrus the other one was tagged with underscore.js
 
@Cerbrus i tried too... when i place it in canvas, i have a light grey background (looks like it's tryin to appear, but cannot...) but if i add it in div into the canvas, i have nothing at all... kinda strange thing... :O
I need the map to be interactive (zoom & so on) and I need it to be inside a canvas to be able then to retrieve an image of the "current & customized" (with current zoom & position) google map element...
 
user2985029
8:42 AM
so the person asking the question may have seen that other question, saw the tag and saw the accepted answer and went no further. we will never know though, because they didn't say much about the research they did before asking the question
 
@AwalGarg \o
 
@argentum47 hi bro!
da hell with the star queue?
 
watcha doing?
 
@argentum47 waking up :p
My sleep schedule has shifted by almost 10 hours so...
 
you are living a dream. I used to wakeup at 2/3/4 when I was at college.
 
8:45 AM
hahaha
 
What the h3ll are you spooks up to ?
 
we are making spookbook
 
2spooky4me
 
: (
 
8:57 AM
Srsly, guys. What's up with all the junk in the starred list?
 
@Kippie Hats!
 
Okay?
 
@Kippie I'd like to up this... Should I star it ?
 
hi
 
There's one Breaking Bad hat too :D
 
9:06 AM
i want little help in calling method in javascript
 
@Kippie better?
 
obj = {};
obj.paramx=0;

obj.getDistortVal = function() {
return parseInt(currValX);
};
obj.setDistortVal = function(new_x) {
currVal = parseInt(new_x);
transformPerspective(box, currVal, 246);
};

var animate = function(e) {
e.preventDefault();
TweenLite.to(obj, 1.2, {setDistortVal: endValX, ease: Power2.easeInOut});
};
 
@FlorianMargaine Much. Thank you
 
@Dramorian Are you developing a game? O.o
;)
 
in this code if i create 2 paramets in setDistortVal then how do i pass those values in TweenLite
@RahulDesai nope
 
9:07 AM
ok
 
Also, now that I see team France is here:
@dystroy, @FlorianMargaine, do you know anything about this? http://chat.stackoverflow.com/transcript/message/20456118#20456118
 
well,... looks like, as you said @Cerbrus, it's not possible to put google map item into canvas element... :/ So, any idea, anyone on how I could do this? (need to generate a google map, with editable zoom/position, and, on event, get a "image file" of it...)
 
@Kippie no idea
I wander in weird rooms
in Python, Dec 9 at 14:19, by corvid
<div>How do you annoy a web developer?</span>
4
 
@FlorianMargaine AGH MY EYES!
 
winterbash has started...
10
it's like...
(How do you annoy a lisp developer?
twitches
 
9:10 AM
try {
    How do you annoy a java programmer?
} catch (Throwable e) { }
 
I don't get it. Is it because the catch block is empty?
 
@Kippie Yeah, means errors go unnoticed
 
@FlorianMargaine ahahahaha
 
Oh, I constantly do that
 
@Kippie *eye twitch*
 
9:12 AM
@Neil I do that in JavaScript many times, and it is perfectly reasonable
 
I could even understand that in javascript
 
;)
 
In Java you could have levels upon levels of calls.. you risk to catch an exception that you really should know about due to some oddball exception way down the chain
 
It can be good for monkey matching old code that you don't want to modify.
 
@Dramorian Why the heck did this get starred? Do we have an auto-upvote bot in here again?
Sorry, Dramorian, didn't mean to ping you
 
9:14 AM
@Kippie: ok
 
@EdiG. starred it. Why?
 
@SecondRikudo you use impress.js and no 3d?!
 
@FlorianMargaine I can always add it later, and I didn't want to spend too much time on visuals
For now it's the content that matters.
 
why does doubleclick event not fire on doubletap?
 
@AwalGarg Because doubletap usually mean "Zoom" and not double click
When in the context of web pages.
There's no concept of "double click" in a touch device.
 
9:22 AM
Yea, you can't double-anything on touch screens.
Well, not reliably.
 
@SecondRikudo Does that mean the ondblclick attribute is not even present in the nodes in mobile browsers?
 
Not sure, I'm not a touch expert.
 
I was wondering if I can use it to detect if we are in mobile...
man I should get a real android device for mobile debugging :( I waste so much time researching silly things :/
 
Yes, you should.
 
Why can't iPad just have a button to transform itself into a brand new nexus 7?! :(
 
9:34 AM
Why can't I buy an exo-suit yet?
 
!!> Array(15).join(+'a') + ' batman!'
 
@FlorianMargaine "NaNNaNNaNNaNNaNNaNNaNNaNNaNNaNNaNNaNNaNNaN batman!"
 
s/\+'a'/NaN/
 
But for how long?
 
9:41 AM
Probably not very long:P
But still, I've been in the top 6 :P
 
I have a hat. My mom knitted it for me so I wouldn't get cold on my way to school. ._.
 
You did screenshot it, right?
 
Dear god, you're right. I have to capture this epic moment!
#4!
 
@Cerbrus Get another hat and you'll be #2
 
Workin' on it :P
Hm, now I need 2 hats to be #2
Hm, I could use a downvote somewhere xD
#3 :P
 
10:04 AM
@Cerbrus link me to a bad answer of yours and I'll settle that
 
-4
A: Whats the right way to use the JavaScript scope?

CerbrusYou'll probably want to declare it as a variable in the function's scope, using var: function B(item) {var myVar = item;} B(12); But if that's the only contents of B, this isn't going to be much good to you, since myVar will only be accessible within the B function.

My worst xD
 
Well... You made me downvote a question here. Your answer isn't good but -4 is more than enough...
 
What does a poster have to do to get some downvotes here xD
 
There ya go
 
Oh kewl xD
That might even get me a shared 1st place
 
10:08 AM
@Cerbrus I'm sorry. I'm always willing to help people asking for upvotes or downvotes here but only if there's enough merit in the post
 
I understand :)
 
If someone asks me to punch them in the face, while I'd normally have a conflict of ethics, if they want a punch in the face, no more conflict :P
 
@Cerbrus I'm sure there's a hat for people being the fourth one to close vote a question, vote to close this one : stackoverflow.com/questions/27481241/…
(almost sure)
(as I've no hat, I'm not the best expert)
 
We'll see :P
 
Wait, why the fourth? What's significant about that?
 
10:10 AM
cv'd
 
@Neil It's a lucky number in China
@Cerbrus too bad, you were the fifth...
 
I think I got that spot unintentionally
 
@dystroy No it's not, it's an unlucky number.
"6" and "8" are the lucky numbers.
Happy Stack Exchange Hats Day!
 
@Unihedro chuuutttt, don't tell him
 
It is lucky, it just has negative luck.
 
10:12 AM
exxactly
 
You win!
 
The chinese skip a lot of floor numbers on a building in order to avoid unlucky numbers
 
A sad feeling.
 
No lie
 
@Neil Yes, that is correct.
 
10:13 AM
@Neil Yes, that's why their buildings fall so often, it's hard to build a robust building with so many holes
 
Or because virtually no building contractor in china applies anti-earthquake tactics in construction because it is too costly
 
0
Q: Node soap server asynchorous

WindrangerI'm writing WS using node-soap. Problem is it's not support asynchorous call. After searching, i found node-soap-ly , using fibers to resolve it. But I can't find any example to install and using it. Any help? Thank you.

 
#1! Fuck yes!
 
@Cerbrus congrats
 
@Cerbrus Screenshot!
 
10:16 AM
I did
 
Now you need to find a 15th
 
"submit an answer to a question with an open bounty and get an upvote"
That should be do-able
 
@Cerbrus no cheating, he
 
Hm?
I'm just looking through a list of the hats :P
 
questions with an open bounty are 99% crap. I wouldn't lose time on that
The reason they have no answer is almost always they shouldn't have been asked on SO
 
10:20 AM
Ugh, I'm reading around a bit...
1
Q: Can an eval access external functions?

mareoraftMy company allows us to write code in a javascript editor online. Other libraries are preloaded, so the code we write has access to these libraries. Specifically, we can use Underscore.js and jQuery.js functions in our code. We can also use our very own library Graphie.js. In an effort to sav...

Yuck
 
The answer looks like superstition.. But in fact there is so much missing information I'm unsure
 
the answer is shit
wow @Cerbrus #1
!!1
 
@FlorianMargaine That didn't make much sense. Maybe you meant: d
 
What what ?
Why did Bil close this question ???
1
Q: how to flip image using jQuery?

taufikI have 10-15 images which are coming from server as per request, i want to use flip image effect for those images using Jquery. Any suggestion and code snippet would be helpful.

 
yeah... random
sounds like we have no way to ping @BillTheLizard
 
10:35 AM
0
A: How can I tell if an element is in a shadow DOM?

CerbrusYou can check if an element has a shadow parent like this: function hasShadowParent(element) { while(element.parentNode && (element = element.parentNode)){ if(element instanceof ShadowRoot){ return true; } } return false; } This uses instanceof over .toS...

Would that be upvote-able?
 
I'd say his question is too broad though...
 
1
Q: how to flip image using jQuery?

taufikI have 10-15 images which are coming from server as per request, i want to use flip image effect for those images using Jquery. Any suggestion and code snippet would be helpful.

 
:3
That could possibly get me into pole position
 
Tssss.... Your answer is a shameless rip-off
 
10:36 AM
I don't wanna share :P
But it uses instanceof
 
And no temporary vars
 
That's cheating here... asking for a fast upvote to people who wouldn't detect you copied another answer...
 
I didn't mean to sneak past that other answer like that, sorry...
 
hehehe
I have a secret hat
 
10:40 AM
Which one?
 
a chameleon, sorry
@Cerbrus you don't have it :P
 
Guys, I'm no longer sharing #1
I don't, tried to, but dunno how to get that one
 
user image
3
congratz
 
I've got pole position by myself in the winter bash :D
Thanks :3
ooooooh
I'm #4, network-wide :D
 
not #1? I disinherit you.
 
10:47 AM
Hi guys, i am having a little problem accessing variable value, can any one help?

i have a json variable like var myVar = [ {"idA": 1, "idB": 2 ....} ]
And i have a function which takes an argument which value will be A, B , C etc

Now the hard part is i have a condition inside function which will target myVar id idA/idB/idC given to the function but i cant find a way to do that.

Here is what i am trying

function xyz (idTarget){
//This doesn't work
if(myVar[window[idTarget]]=='1'){}
//This doesn't work
 
Psh :P
I'm still not sure how to get that frog...
 
chameleon, not frog
 
Eh, yea
Derp
 
@ImranBughio did you try myVar[idTarget] == '1'?
 
@FlorianMargaine i think i tried that as well.. let me try it again
 
10:50 AM
@Cerbrus it's just giving "undefined" i think he start searching for "idTarget" as a key not the value inside the variable
i found function like window(idTarget) should bring forth the value inside the variable to be used as a variable but that doesn't work either.
 
myVar[0].idA
How is that JSON?
 
sorry my bad it's not... i guess it's just a JS object
 

« first day (1521 days earlier)      last day (3419 days later) »