« first day (1719 days earlier)      last day (3223 days later) » 

m59
12:02 AM
That's all it said, with a link =D
 
Looks like I've got a nightmare ahead... what's the best way for this? Results are being fetched via PHP, should I sort via JS or at the query point in PHP? i.imgur.com/TBIuZg0.png
not sort filter*
 
@SomeKittens good looking site. is it yours, or just a service you use?
 
@Luggage Left Sidebar has author credit (hint: it's me!)
 
m59
"Exceptional PHP Developer Opportunity" is as appealing to me as "Exceptional Nursing Home Adultery Opportunity"
 
@James has the client already downloaded the data?
 
12:04 AM
@nick
@nick Coming from a MySQL database
 
hm
 
hm.. i don't see a sidebar at all.. just all scrolly-ness
 
@James what exactly are the results you're trying to fetch?
 
m59
you on a tablet? @Luggage
Sidebar is at the top if so.
 
no, full size browser
we're all talking about gun.io, right?
 
12:08 AM
@nick It's a database of proxies, see proxy-checker.jamesallison.co/…
 
@Luggage oh, you got me all excited. No, gun.io is not mine
 
well, you should take credit for it.
 
Admittedly, I was a little suspicous when you called this "good looking"
 
Just trying to get into your pants.
 
heard he packs a lot of luggage
@James nice
 
12:11 AM
i think the fixed background will work well for a site i'm working on at the moment..
 
@nick
 
yeah you'd probably be better off doing your sort/filter or whatever it is on the server as part of the sql query
 
Jesus keep doing that, why is enter key mapped to send when selecting a mention name.. haha @nick was gonna say I wish PHP room was as responsive as here
 
lol i was wondering
use tab not enter :)
 
!!should i expect microsoft to give me a proper usable lib or just write my own stuff
 
12:18 AM
@Abhishrek You should expect microsoft to give me a proper usable lib
 
Even caprica is trolling !
 
argh.. trying to debug why these polyfills aren't loading int IE8 and IE8 has no network tab..
 
fiddler
 
it's through browserstack
though.. yea.. i could still run somethign on the server-side
maybe webpack-dev-server has a logging option.. that'll help
 
12:35 AM
Can someone familiar with a JS engine point me to an implementation of String.prototype[Symbol.iterator]?
...I think I found it
 
you're welcome
 
Hi guys, I have the following code:

var formInput = document.getElementById('theInput').value;
document.getElementById('demo').innerHTML = formInput;

The code simply gets a value from an inputbox and displays it. However, when I change the input box value, it doesn't change. How do I make sure it always is constantly running?
Sorry if that was explained badly.
 
i think you would have to add a listener to the input element
 
I mean how do I make it so that the innerHTML display updates if the user decides to change the inputbox value.
 
when a change is detected you would update the demo element
 
12:48 AM
Haha the leap second took down one of our service providers
 
Looks like the Australian AWS region just went down
 
rip
 
Event listeners only have click functions, etc?
 
@Tahmid Correct, but there's an awful lot in etc
 
@Tahmid there is an 'input' event.
register an 'input' event listener on your 'theInput' and put your above code inside that.
addEventListener is how you do that: developer.mozilla.org/en-US/docs/Web/API/EventTarget/…
 
12:54 AM
Hmm.. okay thanks guys.
 
1 message moved to Trash can
@Tahmid Please don't post unformatted code - hit Ctrl+K before sending, and see the faq.
 
document.addEventListener("input", function(){
        var formInput = document.getElementById('temperatureValue').value;
        document.getElementById('demo').innerHTML = formInput;
        });
Would something like that be appropriate?
 
1:16 AM
!!caniuse input event
 
It says 0 results
 
DNC
1:41 AM
@James Are you a web developer?
 
@DNC 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.
 
We’ve resolved the connectivity issues some of you have seen. We ran into a LACP bug on the new hardware which broke some machine’s connect.
 
How do I make external variables available in a function created with new Function?
var r = function () { return Math.random(); };
return new Function("return r()-r();");
 
2:05 AM
so, why would you new a Function @KendallFrey? instead of... the normal way?
 
@CSᵠ eval? :D
 
@KendallFrey @CSᵠ Yeah, why? ...this is interesting.
 
I'm generating code on the fly
 
ohh, ok, so then is it better than just eval?
 
probably not much
but I'm not evaling user input
 
2:08 AM
whatever floats your boolean
 
so you already have all the functions defined?
 
yes
I just want to define them in static code to avoid repeating them in the dynamic function body every time
 
hey guys
 
how are the operations defined?
 
oh, my bad
 
2:09 AM
@KendallFrey Not possible
 
What do you mean by "all the functions?"
 
if it's not user input, where do they come from?
 
@copy Maybe not like that, but there must be some way
@phenomnomnominal user input
 
@KendallFrey Pass them as an argument
 
and by "user" I mean "programmer"
@copy I thought of that, wasn't sure if it was a good way
especially since the function will have other arguments that will be supplied by the "user" (bind, I know)
@phenomnomnominal To be precise, I'm generating a function from user input, but not running user input
sigh that's not very precise
Anyway, I've got helper functions I want to use in the dynamic code
So, use parameters?
 
2:14 AM
Put all helpers functions on one object
That's how I did it
 
and pass that as an argument?
 
Yeah
 
kinda more awkward to use, but seems ok
 
can you not .call it with that as the context when you run it?
 
@phenomnomnominal I won't be running it
 
2:17 AM
ahh
 
it's returned to the caller
!!afk zzzzz
 
morning weirdos
 
Hey does anyone know a good website, youtube channel, etc. to learn programming javascript correctly. Ive been mostly self-teaching myself Javascript for a while now and have gotten to a point where my code works well but uses improper techniques. In other words, I need a place to tell what I shouldn't use in my code. Thanks
 
show us an example of your improper technique.
 
Well Ive been using "Inline event handlers" since I started programming and I had no idea this was bad. Or using both Jquery and Javascript in a program
 
2:25 AM
so how did you figure out inline handlers are bad?
 
yo mamma's the morning weirdo!
 
when I posted a question someone mentioned it
 
1st, you can't use jQuery without JS
 
correct. so just keep practicing and you'll get better and better. and you just learnt what @CSᵠ told you.
 
but maybe you're referring mixing raw JS with jQ methods and such..
 
@Loktar KendallFrey is afk: zzzzz
 
this site is running like ass, but check out shapeways.com/product/D7CU9BBLB/…
 
Any guide that you look online for "best practices" will be opinionated with a lot of crap that nobody cares about or is simply moot. When you discover new ways to do stuff and find them cleaner, they become your new good practices.
 
@JoshK YOU USED JQUERY AND JAVASCRIPT IN THE SAME PROGRAM!?!?!
13
 
Yeah @CS I think that is what it was
 
2:28 AM
@CSᵠ that is still not bad (@JoshK)
 
THE CENTER WILL NOT HOLD.
 
it won't 4 sure
 
btw just curious @JoshK how do you know the guy who told you inline handlers are bad was correct? What did you do to verify that he is not just voicing his personal opinion?
 
there should be a law that bans jQ usage until one gets X years of JS experience
 
@CSᵠ where X is the life of the average person. Agreed.
 
2:31 AM
lol :))!
 
I looked it up and there were a bunch of sites that also said it was bad but maybe those could also be opinionated. Personally, I just don't understand why it matters as long as it works
 
New build tool in town.
@JoshK So you still don't know for sure why they are bad, and whether they are bad at all or not. Correct?
 
k, cool
 
yea thats partially why I wanted something reliable
@CSᵠ Yes
 
@JoshK Do you know about MDN?
 
2:33 AM
No
 
!!tell JoshK mdn
 
so, given that you know what they are, how to use them and the alternatives, you can really decide for yourself <-honest advice
 
Ok thanks thats exactly what I needed haha
 
because everything* has a purpose mainly
 
2:36 AM
@CSᵠ When you read your statement again... you'll realize it's very deep...
 
ohh well
 
@JoshK for the inline handlers thing, I'd recommend you to find out whether they are really bad or not, and why, on your own. And tell us when you find out.
 
Ok @Awal Garg Ill look into it ;)
 
nginx amazes me. how come it is so good?!
 
because it's crap, and awesome
 
2:39 AM
your face is crap.
 
you're your own face
 
no. that's zirak.
 
no! you are Zirak!
 
I... uh.. I will not commit the sin of resembling the overlord of JS.
 
too late, JS already oversees your resemblance to IT
 
2:42 AM
forgive me
2
 
jQuery, angularJS, or both?
 
both. both are crap indeed.
 
@Woodrow why?
 
Just wanted to get some opinions from javascripters, as I am new-ish to the field
 
2:45 AM
why don't people read the title of this room, and goto the special room and/or room? why????
 
thanks
 
How do I remove, in production, react's message: "Download the React DevTools for a better development experience: https://fb.me/react-devtools" ?
 
jquery's animations / draggables / resizables looks powerful.. not crap.
 
@AwalGarg that's really not true
@AwalGarg how do you feel about screwdrivers?
 
er.. I guess that's jqueryUI library
 
2:47 AM
@phenomnomnominal it is true in my opinion. I don't know what kind of screwdrivers you are talking about.
 
A screwdriver is a popular alcoholic highball drink made with orange juice and vodka. While the basic drink is simply the two ingredients, there are many variations; the most common one is made with one part vodka, one part of any kind of orange soda, and one part of orange juice. Many of the variations have different names in different parts of the world. The International Bartender Association has designated this cocktail as an IBA Official Cocktail. == History == This drink appears in literature as early as 1938 "And answered it "The famous Smirnoff Screwdriver", Just pour a jigger of smirnoff...
 
The tool. A screwdriver. For screwing in screws.
 
what kind of screws?
 
any kind of screws
 
question too broad
 
2:48 AM
you use screwdrivers for any type of screws ?!?!?!?
vote to close.
 
@CSᵠ You got a point sir...
 
you guys are dicks
 
@phenomnomnominal please read the help center on how to ask good questions to get good answers.
XD
 
no! you're a guy!
 
kicked
:)
 
2:51 AM
lol, that was unnecessary
 
kicked.
:)
 
indeed. this kicking thing is going too far.
you might think it looks like a good joke but rarely.
meh, gth.
 
that was my first kick :) ever
wtg @phenomnomnominal
^it was supposed to be a g from starters
 
Ok I've got it. Inline Event Handlers are bad but not too bad because it is easier to manage your code when your HTML CSS and Javascript are all separate especially when making big projects!
 
there's almost never suct a thing as X being either bad or good in the general sense
 
2:58 AM
Well based on what I just said, as long as the Handler isn't too complicated and doesn't affect the management of the overall code, I couldn't care less. For example, I think they are fine for calling a function onclick for a button.
 
still, remember SoC
 
SoC?
 
and DRY
 
But what about KISS, if the event handler is much simpler than an entire complicated function of code....
;)
 
@CSᵠ Ohhhhh...... THE REVELATION.....
 
3:06 AM
@JoshK of course, the KISS, always remember KISS your project once in a while :)
@Gideon which one?
 
@CSᵠ I will definitely, I hope it just doesn't reject me :P
 
@JoshK kiss applies to the long term as well. And long term is will be simpler to maintain if your concerns are well separated.
of course, you can always argue about which concerns need to be separated
 
Back to the entire point about opinions haha
 
ohai
 
ahoy
 
3:14 AM
What are we arguing about now?
 
time
 
@AwalGarg doesn't like Angular, and wouldn't let me rope him in to saying that he wouldn't like it if I stabbed him in the eye with a screwdriver either, but they're still a useful tool.
 
WHAT
LEMME AT 'EM
 
yeah, that backfired a bit
 
the point is still valid :P
JQuery and Angular are both useful tools. But tools have to be used properly.
 
3:17 AM
what was supposed to be the screwdriver analogy @phenomnomnominal
?
 
hello anyone has experience with web crawler ??
 
Had I been allowed to get there, then yes :P
 
which one?
 
3:30 AM
Good morning everyone
 
Hi James
 
@James Another Australian! @monners will loooooove you!
 
I've got a really weird Angular thing going on
 
I said they are crap, not "not useful". FFS I was kidding anyways.
 
You're half-right tho
 
3:33 AM
I'm entering text in an input box, hit enter and the enter is causing a button click to be triggered
any ideas why
 
The PHP community is way more mature than you kids. They accept happily that their language is shitty and continue doing awesome things with it.
4
 
@James Maybe because that button is of type='submit'?
 
Nope
 
@AwalGarg only those outside the community say it's crap
 
@Gideon <button class="btn btn-sm btn-default btn-save" ng-click="removeItem($parent.$index,$index)" ng-show="!rowform.$visible"><i class="fa fa-times"></i></button>
I've removed the bootstrap classes but it still happens, I've removed the entire bootstrap library and it still happens
 
3:35 AM
@CSᵠ meh most good php devs know how much it sucks. doesn't stop them from loving it.
 
so I think it's an angular thing, but I have no idea why angular would be doing that
 
@James How about the markup of the input text?
 
@James ng-submit?
 
> Languages don't suck. Your code does.. - Lincoln
 
it's quirky, but can't be crap while it kept the whole internet for all this years...
 
3:36 AM
@Gideon <input class="form-control input-sm" type="text" ng-pattern="/([a-zA-Z0-9'])/" value="" ng-model="addressSearch" id="autocomplete" data-item-index="{{ $index }}" google-address />
@SomeKittens nope
google-address is a directive, that uses the address plugin to find addresses
 
There are two kinds of languages. Those everyone complains about and those no one uses.
 
point
 
@SomeKittens And Python
 
@uselesschien Said no die-hard language fans ever...
 
@SomeKittens So basically two kinds of languages - Not Haskell, and Haskell.
fair enough
 
3:37 AM
@Gideon There are die-hard language fans?
 
@uselesschien Yep, they're very biased about their preferred language... Look about programming blogs.
 
Haskell is being used, by the way
 
all the people in the C++ lounge for instance... but they are secretly jealous of us as well :D
<insert obligatory haskell xkcd here>
 
@AwalGarg Hahaha....
 
and of course... as i predicted a few days ago: JS reached an all time high #1 place
 
3:41 AM
@Gideon I'll make a plunkr that duplicates what's happening
 
… in questions
 
@AwalGarg No, there are 11 kinds of languages: Assembly, Error: 0xC0000005
 
0xC ? hmm...
 
A more interesting metric would be number of projects on github vs questions on SO.
 
Guys, what do you do when you personally heard a person said: ".... but JavaScript is not even an official language!"
 
3:42 AM
@Gideon print them out the spec.
 
@Gideon kick in the nuts!
 
<self-promotion>use especser for reading the spec. kthnx!</self-promotion>
 
!!s/<[^>]+>//
 
@CSᵠ use especser for reading the spec. kthnx!</self-promotion> (source)
 
@CSᵠ your screen!
 
3:45 AM
awesome cthulu invasion... cpu fan started
 
I can see it from here. The blood weeping!
 
this could also be interpreted as: The #1 most misunderstood programming language of ALL TIME is... click to find out
 
@CSᵠ I'm actually, some part of mind, thinking the same thing.... :-(
 
hmm... maybe it's crap
 
Yeah that's my point, what are the most used langauges, with the fewest questions.
 
3:50 AM
@copy I am reading that book you recommended (very interesting btw) and it explains stuff about memory registers etc. Where would be a good place to ask related questions?
 
SO
 
well it doesn't look like programming related :/
 
Assembly is programming
 
@AwalGarg does it talk about having a good memory when you handle cash registers ?
 
@CSᵠ lol no
I don't have a real question I just thought copy will say "ping me anytime with whatever question you have" :P
 
3:54 AM
Ping me but only if you've done some research
 
:D
 
Is process.cwd() a reliable way of retrieving the project root?
 
No
Use __dirname
 
Of course it's an angular 'feature'
 
__dirname wont get me what I want while working inside a folder, like "controllers/"
 
3:57 AM
yeah process.cwd() can be decieving. If you are in ~ and do node foo/bar/baz.js, process.cwd() will point to ~ only.
 
@NickDugger In that case you'd use __dirname + "/.."
 
(or path.join)
 
Yeah. I was trying for a clever way of avoiding that
Thankies anyways
 
yw cutie
 
4:25 AM
@NickDugger does require.main.filename get you what you want?
 
Hey guys, I am banging my head to understand the Array and looping concepts in JS. Could anyone please shed some light on that?
 
@uselesschien Thanks for the useful resource
 
Good morning
 
Morning
 
5:04 AM
Good Morning
 
Damn, it tastes like someone peed in the coffeemaker :/
 
how to check file size in javascript?
and is it works in all browsers
?
 
@madu just scroll upwards.... Your question has been asked yesterday, I think.
 
@madu Have you looked at stackoverflow.com/a/3717847/957731? Literally the first hit on google
 
yes i asked before no answer for that?
 
5:14 AM
@ivarni I totally want to post that... beats me.
@ivarni How'd you know it tastes like pee? So... um.. you've tasted pee before? Um... forget it.
 
@Gideon I know how it smells and have made assumptions about how it tastes based on previous experiences with smell and taste of other substances
 
hellow
 
@kannanD.S 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.
 
caprica is becoming slow
and old
 
yes Caprica
1 sec
Am trying to integrate Raphael Sketch Pad on a web page,large devices its working properly, but its not working on touch devices. how can i solve this issue? am pasting the site link here pl z check and give me a feed back ianli.com/sketchpad
 
5:20 AM
@Mr_Green But @CapricaSix was just born on 2011.....
 
hellow
 
got it
 
^ thoughts ?
 
@CSᵠ Wait... still reading. (I'm not a fast reader.)
 
@Gideon yeah so?
 
5:26 AM
@Mr_Green maybe it's a designed delay
 
nah it was faster before
 
@CSᵠ Haaah.... panting TL;DR.
 
must be that new ES6 thrown in
 
0
Q: Browserify-shim using google as a dependency

vamsiampoluI use a couple of libraries from google viz. google-maps google-picker google client api for authentication I would like to shim L.Google using browserify-shim: "browserify-shim": { "google": "global:google", "L.Google": { "depends": [ "leaflet:L", "google" ] } ... } I get this...

 
@CSᵠ did you notice the tag?
 
5:34 AM
@phenomnomnominal no, but something ticked me off, couldn't put the finger on it
 
it's satire?
 
doesn't really fit
 
> Universal values like undefined and null are useful values to return if you want to indicate system failure, out of memory error, user error, invalid memory location, timeout, nothing, something, anything. -- WAT
Their linked list implementation is horrible
 
@JanDvorak guess I skimmed a lot :P
@JanDvorak feel free to bin the link, please even
 
nah, I'll just tear it down instead. More fun.
> you can prove that the bottom rung of your ladder exists, and you can get from rung n to rung (n-1), then you’ll eventually get off the ladder
 
5:43 AM
time.
 
user406009
I really wish JS didn't have undefined.
 
False. You also need to prove the ladder has finitely many rungs. This in turn implies there is a lowest rung.
 
then how would you know if your object is defined or undefined?
 
@CSᵠ can't the compiler check for me?
Haskell doesn't have null.
 
@JanDvorak you must be able to know
 
5:46 AM
@CSᵠ sure. Have it shout at me if I use something I didn't set
at compile time
 
@JanDvorak can't see a problem with that
are people missing NULL in haskell ?
 
lol ^
 
if you want optional values, use Maybe
data Maybe a = Nothing | Just a
 
user406009
Basically optional values are opt-in instead of opt-out.
 
5:48 AM
that
It's even a monad, which comes handy at times
The closest equivalent to the Maybe monad would be to work with nullable values and if any of them is null, instead of throwing, your function returns null automatially.
> I think blindly following the stuff here will prove to be incalculably beneficial for you.
WAT
That. Statement. Speaks. For. Itself.
 
@JanDvorak sounds legit
 
That blog pops up a Disqus login window. Disqus pops up a Google login window. Gotta love nested login popups.
> Greg Bagley • 2 hours ago
Only after I finished reading did I see the tag 'bad-theory'. Well played author. Well played.
 
0
Q: Angular JS unit test for web-service response without mocking

RamshadI'm making a unit test for angular js application in Karma. There is a part where my controller function makes a web-service call to the server. I would like to verify the response data from the server side using unit testing. I have looked at many tutorials. However, they are suggesting to ma...

 
I think my favorite language from now on is Assembly.
 
@AwalGarg Because it has GOTO right?
 
5:59 AM
my all time favorite is css
 
Anybody there?
 

« first day (1719 days earlier)      last day (3223 days later) »