« first day (1445 days earlier)      last day (3501 days later) » 

10:00 AM
if someone has Mac+Safari, I would really be interested :)
 
@Sippy hi dint expect t see you here buddy
 
@Gotalove Why's that?
 
would someone have just 3 seconds for that ? :)
 
hey guys, could anyone help me with something, what´s wrong with this code?:
$(document).ready(function(){

$("#btnGaleria").on("click" ,function(){
$('#content').ScrollTo();
});
});
i´m trying to use the scrollTo from jquery
i also have the source:
<script src="js/jquery-min.js"></script>
<script src="js/index.js"></script>
<script src="js/jquery-scrollto.js"></script>
what am i doing wrong?
 
@Sippy coz I dint expect to come here
 
10:20 AM
@Gotalove wat
 
I have been in this room very few times so was surprised you were here as well thats all @Sippy
 
... hello ...
 
@Gotalove Ah now it makes sense.
 
Do some of you have a normal QWERTY keyboard (i don't, i have french AZERTY) ?
hello @AwalGarg
 
@Japa you are not formatting your code.
 
10:23 AM
I'm a wannabe web developer, I'm sposed to be here :D
 
hehe +1 sippy
 
@Sippy me too! me too!
@Basj I do. And so do many other people here :)
Except @JanDvorak who uses Dvorak.
 
@AwalGarg ok :) what keycode do you get when you do CTRL+PLUS or CTRL+MINUS on asquare.net/javascript/tests/KeyCode.html ?
 
@Japa I'm pretty sure you have to specify somewhere for it to scroll to, don't you?
 
> keydown keyCode=107 (k) which=107 (k) charCode=0
keyup keyCode=107 (k) which=107 (k) charCode=0
keyup keyCode=17 which=17 charCode=0
(ctrl+)
 
10:25 AM
i was under the impression $obj.ScrollTo($target) was like
$obj is the container with a scrollbar and $target is where you want it to scroll to
 
> keydown keyCode=109 (m) which=109 (m) charCode=0
keyup keyCode=109 (m) which=109 (m) charCode=0
keyup keyCode=17 which=17 charCode=0
(ctrl-)
 
which can be a jQ selected DOM element, or an absolute value in px, or something
 
@AwalGarg ok thank you ! so + / - seem to be 107 and 109 ?
 
@Basj Can confirm :)
 
yes
 
10:27 AM
Awal how do you do that quote thing with the line
 
Ok! Thanks! Which OS/browser ? @Sippy @AwalGarg
 
> Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.120 Safari/537.36
> like this ;p
 
i get 187 and 189 in win 8.1 chrome 37
 
ye like that
:P
 
@AwalGarg what is it ? Chrome or Safari ?
 
10:28 AM
@Sippy > text
 
@rwollr arghhh... me too, I had this before too
 
> Windows 7 Enterprise SP2 with Chrome 37.0.2062.124 m
Oooo
 
though it would appear 187 is - and 189 is =/+
it doesn't give me anything different for doing ctrl + +/-
 
@Basj haha, Chrome. (and you should learn how to read user agents ;p)
 
@AwalGarg yes ;)
 
10:29 AM
@AwalGarg How did you get your user agent?
Such a noob web dev lel
 
@AwalGarg why is it written Safari/537 then ?
 
@Sippy on that same page
 
Oh...
whistles
 
@Basj because chrome runs on webkit
 
@AwalGarg lol ok :) And why is it written safari then ;) ?
 
10:30 AM
@Basj apple/webkit, safari = made by apple.
 
ok
 
ok is ok... but you can always upvote any of my posts to show gratitude :)
 
@BenjaminGruenbaum Yes
 
@SurajVerma BenjaminGruenbaum is afk: lunch
@SurajVerma 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.
 
@AwalGarg repwhore!
 
10:32 AM
@Sippy shhhhhhhh!!!
!!when did you live?
 
@AwalGarg Indeed
 
!!stat
 
@JanDvorak You (http://stackoverflow.com/users/499214/jan-dvorak) have 14591 reputation, earned 0 rep today, asked 0 questions, gave 516 answers, for a q:a ratio of H̸̡̪̯ͨ͊̽̅̾̎Ȩ̬̩̾͛ͪ̈́̀́͘ ̶̧̨̱̹̭̯ͧ̾ͬC̷̙̲̝͖ͭ̏ͥͮ͟Oͮ͏̮̪̝͍M̲̖͊̒ͪͩͬ̚̚͜Ȇ̴̟̟͙̞ͩ͌͝S̨̥̫͎̭ͯ̿̔̀ͅ.
avg. rep/post: 28.27. Badges: 6g 20s 40b
 
!!info
 
@JanDvorak I awoke on Mon, 29 Sep 2014 13:14:45 GMT (that's about 21 hours ago), got invoked 43 times, learned 308 commands
 
10:34 AM
@AwalGarg could you add your data here please (I would thank you much!) : demo.firepad.io/#SaEjLZDFna
 
@Basj there is no linux tab ;(
@CapricaSix liar liar set on fire!
 
@AwalGarg I have no time to investigate Linux, I'll do this later ;)
 
@Basj i'll make one, dun worry.
 
@AwalGarg thanks so much !
@Sippy thanks a lot for participating !
 
@Basj done :)
 
10:39 AM
@Sippy so you get the same than me on IE (187 54) ?
 
@Basj You're welcome.
187 is a hyphen.
Not a minus symbol, they appear to be different.
 
@Sippy you set results for IE too, is it right ?
 
My set results for IE are the same as Chrome
 
thanks @AwalGarg :) Don't you have Mac or Win too ? ;)
 
107, 109 and 187.
 
10:40 AM
@Sippy so it's not correct here in your IE column ? demo.firepad.io/#SaEjLZDFna
@Sippy is there two different keys for hyphen and minus ??
 
There is on my keyboard, yes.
One on the keypad and one on the main keyboard.
 
ohhh ok, which one is the one on the keypad : minus ? and main keyboard : hyphen ?
 
Yes.
 
@Basj I used to use Windows but I have long since "upgraded" to Linux :)
 
@AwalGarg ok :) what - did you test ? The - from keyboard or - from main kbd ?
 
10:43 AM
!!s/keyboard/keypad/
 
@Sippy @AwalGarg ok :) what - did you test ? The - from keypad or - from main kbd ? (source)
 
@Basj both are the same thing.
 
they're not, awal.
 
@Sippy wanna bet?
 
Hyphen is 187, - symbol is 109.
They do the same thing
but they are actually separate.
 
10:44 AM
ahh that way..
 
i can't get it to produce 109
because i don't have a numpad
i always use - and = for -/+
 
@AwalGarg in demo.firepad.io/#SaEjLZDFna did you use keypad or main keyboard's -
@rwollr, would you want to add your results to demo.firepad.io/#SaEjLZDFna ? thanks in advance :)
 
window.onkeyup = function(e){console.log(e.which)}
a better and more stream-lined test
@Basj the keypad
(189 with the main keyboard)
 
@AwalGarg could I ask you to do it again with main keyboard's (not keypad) ? :)
 
@Basj 189
 
10:48 AM
@AwalGarg can you paste it here demo.firepad.io/#SaEjLZDFna ... i could be lost ;)
@rwollr do you have a QWERTY as wwell ?
 
@Basj done
 
yup
 
> Cameyo, now with encryption

Cameyo's latest version now includes data encryption. When enabled, this feature encrypts data created by virtual apps during runtime, using AES-128 encryption.
\o/
 
@AwalGarg can I ask you last thing CTRL + PLUS, with the "main" + (not keypad) ;)
 
@Basj doing that
 
10:50 AM
btw thanks everybody for participating, that's very nice !
 
i know you didn't want any more external libraries but
 
> CTRL +keypad (Sippy, keybGB) 107 107
CTRL -keypad (Sippy, keybGB) 109 109
CTRL +main (Sippy, keybGB) 187 187
CTRL -main (Sippy, keybGB) 189 189
 
you can also see the keycodes on that page
 
@Basj done
also @Basj ever tried google webforms? They are awesome for such things :D
 
@AwalGarg what is it ?
 
10:51 AM
like this firepad thing but easier to use :D
 
!!tell Basj google google forms
 
ok great !
 
@Basj also, ever tried Google? It is awesome for searching for information ;p
 
@AwalGarg Lol don't be facetious
He's happy :D
 
10:52 AM
haha just kidding
 
@rwollr : i started with mousetrap that you showed before, it works, except CTRL PLUS , there's an issue / pull request, etc.
@Sippy Yes I am :) haha
btw what happens if someone deletes everything ??
 
lemme try
;p
 
is there version management in firepad ?? :)
hahaha
someone did
 
lol gone
hahahaha
 
luckily i copy/pasted to a local file
has someone a Mac here ? :)
 
10:55 AM
@Basj @AbhishekHingnikar is an apple boy. He must have it :D
 
What am I supposed to do now if I want to catch CTRL PLUS and CTRL MINUS ?? there are soooooo many cases..........
 
well not the problem at hand but
i wouldn't do CTRL PLUS or CTRL MINUS to start with
any time i try to test them it just changes the zoom level :B
 
@rwollr sure but I want to override this because my project is bigpicture.bi/demo , so I really need to override CTRL PLUS / MINUS
 
@Basj you wanna detect browser zooming, right?
 
lol interesting
 
10:58 AM
 
yes
 
for me, it captures CTRL PLUS already but CTRL MINUS doesn't work
 
> Before asking inform yourself on the XY problem goo.gl/taIqf
84
Q: Catch browser's "zoom" event in JavaScript

user123093Is it possible to detect, using JavaScript, when the user changes the zoom in a page? I simply want to catch a "zoom" event and respond to it (similar to window.onresize event). Thanks.

 
@AwalGarg I know this problem... But why is it a XY problem here ?
 
@Basj read the above post :D
 
10:59 AM
@AwalGarg the accepted answer is here "there is no solution", so I have to find a solution myself with catching CTRL PLUS keybcodes, etc.
 
"One way to detect zoom level changes relies on the fact that percentage values are not zoomed. A percentage value is relative to the viewport width, and thus unaffected by page zoom. If you insert two elements, one with a position in percentages, and one with the same position in pixels, they’ll move apart when the page is zoomed. Find the ratio between the positions of both elements and you’ve got the zoom level. See test case."
hahahaha
 
@Basj The answer with 6 upvotes.
 
that's so hacky
 
@AwalGarg : it works 100% on my computer (keybFR), so there is no problem at all with listening to keycodes... I only need to adapt to keyUS keycodes, that's all
@AwalGarg too dirty and having a waiting time is not good for my purpose (i could explain but it would be long, i have done tests on this already)
 
@Basj ok well. but remember that those aren't the only two key sets.
 
11:02 AM
@AwalGarg yes, but I can imagine there exists a solution somewhere to normalize detection of + button and - button... Where ? ;)
 
@Basj TBH, I dunno. I am assuming you have already done your part of researching, right?
second thing is, ctrl+ and ctrl- aren't the only ways to zoom... you know there are ui elems to do that, right?
 
@AwalGarg that's right
 
and that +- thing would NOT catch that kind of zoom.
@Basj and you are ok with that?
 
@rwollr True but there's not really another way to do it :/
 
@AwalGarg i know...
 
11:06 AM
and that is why I said this is an XY problem.
 
@AwalGarg but that's not a real problem... My tool isn't made to use UI zoom buttons but only Keyshortcut OR mousewheel / trackpad
 
wat
which ui zoom buttons are you talking about?
 
Hi. My javascript app reads CSV files. However, when it reads a 20MB file, it takes about 200MB in RAM. However, the code "works" fine. Is this question on topic here at SO?
 
@AwalGarg I mean in the menu View, Zoom
@AwalGarg I only need to handle CTRL+PLUS/MINUS + mousewheel... that's enough for the user of my tool
 
@Basj then you can use the window.onresize event. It is fired on zoom by modern browsers.
 
11:11 AM
@AwalGarg oh really? do you have a jsfiddle ?
 
@Basj window.onresize = function(){console.log("resized!")}
put this in you console and hit enter
then zoom, you should see the text being logged in the console.
(make sure you are not using ie5.5)
 
@AwalGarg lol
 
If code I posted works on IE6, tell me. I would change it accordingly so it doesn't work in there.
 
It works @AwalGarg, but then it doesn't prevent zooming to be done .... I would like to handle zooming myself... and not let standard zooming to be done
@AwalGarg haha
 
@Basj this is not possible. This is "just" not possible.
Like you can't prevent user from closing your website, you can't prevent him from zooming.
 
11:14 AM
@AwalGarg It is possible ! :) It works 100% on my french keyboard with all the browsers because I use e.preventDefault() after catching CTRL PLUS
@AwalGarg False. Believe me, I worked on this during weeks. The only problem left now, is how to catch the good key shortcuts ;)
 
@Basj Do you know some browsers and OSes default to a zoom level? Your script loads after that happens, and it fails.
 
@AwalGarg no no, I tried on these browsers and it works
 
@Basj hmm, maybe you can try catching the key output code instead of the key code. Since it shall be definite, I guess.
 
@AwalGarg ohh i did not know about this. what is output code ?
 
@Basj neither do I know completely... lemme check.
 
11:21 AM
Can one of you change avatar please
I know they're diff colours but it's so hard to look at lol
 
loll
 
@Basj window.onkeyup = function(e){console.log(e.keyIdentifier)} try this in console and make people hit keys for you
@Sippy I shall not move!!!
 
Lol
Screw you guy!
 
@AwalGarg i get undefined !
 
@Basj which browser?
 
11:24 AM
@AwalGarg FF
 
FF = Forget Firefox
@firefox I don't like you ;(
 
Lol
 
@Basj seems like a bug... it is reported on the code project too.
 
I stopped using FF in the days of XP when it felt like driving a flatloader
 
@AwalGarg ok so I cannot use this ;)
 
11:26 AM
FF plays videos better than chrome though.
@BenjaminGruenbaum hey where is keyIdentifier s spec written? Can't find it! WTF
 
@AwalGarg BenjaminGruenbaum is afk: lunch
 
@CapricaSix shutup
 
@AwalGarg ??
 
According to msdn.microsoft.com/en-us/library/ie/dn792847%28v=vs.85%29.aspx IE should support readAsBinaryString (part of the FileReader class) but when I debug in IE, it fails.. Does any one know for sure?
 
@BenjaminGruenbaum keypressEvent.keyIdentifier (FF returns null)
ahh leave it... still in draft.
 
11:33 AM
ok then
 
@Basj now you can just go hunt for all the keycodes for different setups and use them. Good luck bro ;p
 
@AwalGarg there surely is something in jquery or something else to deal with this no ?
 
@Basj Not that I know off in Vanilla JS. And I don't use jquery.
 
so sad !
 
If you can drop support for FF (which is not a good idea), you can use keyIdentifier which will literally cut 80% of your work.
 
11:37 AM
@AwalGarg impossible to drop FF support !
 
lol yes
 
angular $httpBackend how can i test that a request came back with a 404? I have set the request to return 404, but how can I actually test for this?
 
anyways, why do you want to handle zooming yourself @Basj?
It is there for the user, for a reason. User should have complete freedom to zoom as much in and out they want.
 
In AngularJS can you redirect to cshtml or does it have to redirect to a html page?
 
@AwalGarg try : bigpicture.bi/demo and use PAGE UP / PAGE DOWN
4
 
11:44 AM
@Basj nice...
 
@AwalGarg you can zoom (nearly) infinitely... which is not possible with standard page zooming in browser (it's only 10% to 1000% but not more)
 
@Basj Is this yours?
 
@Sippy yes
 
This is cool as fuck
Does this lib already exist?
Or did you make it?
 
@Sippy I made all
 
11:46 AM
Impressive, man.
 
@Sippy thanks !
Have a look at bigpicture.bi/1898oa
you can "store" hundreds of recipes in one screen
you can see them by zooming
there is only 2 recipes for now : moussaka and CHAMPIGNONS
 
ok so you @Basj have a french keyboard right?
 
@AwalGarg right
that's why the CTRL PLUS / MINUS works only with my own layout
 
@Basj window.onkeypress = function(e){console.log(e.charCode);} tell me the output of this when you press the hyphen key.
 
@AwalGarg 45 or 54 (with or without SHIFT)
 
11:50 AM
@Basj and this is the same as mine, and I expect this to be standard across all browsers and OSes...
@Sippy try?
 
@AwalGarg make it in fiddle
 
BACK ! with another problem :)
 
@Basj what about +? (this should have different results from the main key and the numeric keypad)
@Sippy you just need to type that in your console man! what's so difficult?
 
@AwalGarg BUT it doesn't work with window.onkeydown... and I hope onkeypress won't be too 'late' to prevent browser zooming to happen :)
 
SyntaxError: Unexpected token (
I don't debug in chrome a lot lol
 
11:52 AM
@Basj onkeypress is standard.
 
Ok got it
What do you want?
I mean what key
 
@AwalGarg do you manage to catch CTRL + PLUS with keypress ? which code would you use
 
@Basj you just match the plus with this. match ctrl with the meta key switch.
 
Cool fiddle :D
oops
 
@AwalGarg do you manage to listen to the CTRL PLUS ?
 
11:55 AM
@Basj yes, I do.
 
@AwalGarg does it work for all browsers ?
 
@Basj I assume so. But I have only tested on chromeUbuntu.
 
@AwalGarg what difference between onkeypress and onkeydown ?
 
It should work for all browsers with the same output because charcodes follow a standard.
@Basj keypress is key down and then keyup. key down is just key going down.
 

« first day (1445 days earlier)      last day (3501 days later) »