« first day (942 days earlier)      last day (2846 days later) » 

5:05 AM
Hello,
how to make grayscale map?
 
 
1 hour later…
6:08 AM
posted on November 28, 2015

New Cyanide and Happiness Comic

 
Abe
IF JAVASCRIPT IS SO GREAT WHY DOES IT NEED JAVA TO WORK, GENIUS?
 
 
2 hours later…
8:21 AM
@Abe And also script, don't forget that
 
Abe
stupid script!
 
So should I pull the rug out from all the IE8/9/10 users come January, or should I wait longer?
I was thinking waiting till Feb so Windows Update has time to upgrade people.
 
Abe
IE10 is easy to support
 
but do I "have to" support it?
 
Abe
also msie9 for most of cases to be fair
you have, no. you should support it for at least one more year
or less probably
most of msie10 installs got upgraded automatically to msie11
 
8:31 AM
What if I am running an e-commerce site and I want visitors to use a secure browser to do their shopping? With no security updates available for old versions, would I not be putting people at risk by not mandating a more up to date browser?
 
Abe
eh, so what you do with old browsers? you completely deny them the navigation?
 
I mean the liability ultimately falls on them, but just makes me itch knowing people will be using insecure versions.
No I would provide notification saying their browser is not supported and direct them to MS site to upgrade to the next available supported version.
I know I can't force them, but giving them a notice when they visit should hammer it into their head that they should upgrade.
The MS post talks about security a lot and I would expect most people to heed that advice.
 
Abe
you can that with all browsers yes, but you could try supporting at least msie10
 
US Browser Stats (Oct 2015)
---------------------------
IE 8 2.72%
IE 9 2.71%
IE 10 2.37%
IE 11 18.89%
IE 12 1.83%
I'd expect those numbers to change a lot come upgrade time in Jan
If I see the IE10 numbers have not reduced a lot I'll support it.
as of right now there are less IE10 users than IE8/9
 
Abe
yes because it got automatically upgraded to msie11
... for most of them
those 2.3 are those that disabled automatic upgrades
frankly we shouldn't even care of them
the problem is actually msie9
 
8:39 AM
They don't have an upgrade option right?
 
Abe
ms put so much effort making the "get windows 10" icon appear in my tray
i wonder why they don't do the same with msie...
 
$$$$
 
 
4 hours later…
crl
12:55 PM
pff it's GeniusScript
 
 
1 hour later…
1:55 PM
posted on November 28, 2015 by Pedro Botelho

Hacker Scripts * P Vs. NP * Sass Print Design * How to animate "box-shadow" * Frameworks * Animated SVG vs GIF Collective #196 was written by Pedro Botelho and published on Codrops.

 
 
1 hour later…
2:56 PM
canada sucks
 
need to travel due to an emergency and dont have the appropriate travel documents? too bad
 
Abe
Black Friday Pep Talk. #wearetarget (Via http://bit.ly/1wBQ7Lu) https://t.co/rEqcw53E6d
 
3:32 PM
could we please stop calling it HTML5 and call it HTML again
it's the standard
hype over
/rant
 
3:45 PM
but we like hype
dear ALA, wtf does this article have to do with frameworks? alistapart.com/article/frameworks
 
 
1 hour later…
5:16 PM
Hey guys can someone please tell me the proper way to get the height and width properties of an element using JS.
I am using var h = document.getElementById("name").style.height;
and yet it's null each time
in the main.css file it's height property is set to 200px
 
god why did I think playing pokemon red again was a good idea..?
 
5:32 PM
13
Q: How to get an HTML element's style values in javascript?

stanI am looking for a way to retrieve the style from an element that has a style set upon it by the style tag. <style> #box {width: 100px;} </style> In the body <div id="box"></div> I'm looking for straight javascript without the use of libraries. I tried the following, but keep receiving ...

 
5:44 PM
@cimmanon Thank you for that. Can javascript do mathmatical equations on a return that has the string px in it? for example if I say 200 - 200px will that work?
 
don't do that
 
well the problem is that getComputedStyle returns the type of measurement ie. 200px vs just 200
should I just split the string
 
yeah, you should extract the number out of it
just stripping off all the letters would work too, like with a regular expression
!!>"200px".replace(/[a-z]/g, '')
 
@StephanMuller ""
@StephanMuller "200"
 
!!>"200em".replace(/[a-z]/g, '')
 
5:50 PM
@StephanMuller "200"
 
the great thing about a regex is that you can make it match whatever you need, in this case simply 'all letters' and replace that with an empty string, so the remainder is always a number
 
!!> is regex syntax?
 
@Timg "SyntaxError: missing ; before statement"
 
looking it up on w3 and not seeing how to use it
 
no !!> is a syntax to make the bot perform javascript
 
5:52 PM
/pattern/modifiers;
 
that's just for this room
 
is all i'm getting
cause as far as regex wouldn't it be as simple as /d*
 
the /[a-z]/g part of what I said is the regular expression
 
and that would grab 200
 
oh sure that should work too, but instead of using replace you should use match and get the matching string, like this
!!> "200px".match(/\d+/)
 
5:54 PM
@StephanMuller "200"
 
though the bot doesn't show it's actually returned as an array with 1 item, so you'd need "200px".match(/\d+/)[0] to grab the first item in the array
!!> "200px".match(/\d+/)[0]
 
@StephanMuller "200"
 
strange behaviour, caprica
!!afk cooking
 
bam
var x = getComputedStyle(box).height.match(/\d*/);
 
don't forget the [0] there though :P
also let me rephrase
 
5:56 PM
it picks it up fine
 
!!afk making pancakes for dinner
 
without it...
 
user1881400
6:22 PM
Are there any rubyists out there? I've been itching to know the rationale behind github.com/bbatsov/ruby-style-guide#no-explicit-return (no explicit return). If the return is left implicit, how does the reader know it was intentional? How can we prevent somebody from adding a few lines of code below the implicit return, causing the returned value to change (and breaking anything relying on it)?
 
6:44 PM
@FizzledOut what's to keep that same person from rewriting the program entirely, deleting the contents of your hard disk?
it's a moot point
if you can change the code, you have full control over what it does
think of it as removing the necessity to have the "return" in the return statement
 
 
2 hours later…
8:40 PM
!!>"default".match(/(\d+)/)[0]
 
@CSᵠ "TypeError: \"default\".match(...) is null"
 
@StephanMuller ^
!!>"default".match(/(\d+)/)
 
@CSᵠ "null"
 
 
2 hours later…
crl
10:49 PM
Does the :not selector accepts sub selectors like :not(div a)? seems like no
!!mdn css not
 

« first day (942 days earlier)      last day (2846 days later) »