« first day (1579 days earlier)      last day (3383 days later) » 

12:00 AM
I've been stuck on this bug for hours now and was wondering if anyone was willing to help
Trying to literally copy and paste this modal code into another website but for some reason not able to get it to work
 
user1596138
Lol
 
> just ask your question, and if anyone's free and interested they'll help.
 
sure
So I've got a modal that is part of a framework based off bootstrap. It can be found here: branchow.com/development/competition/modal/modal.html. I've attempted to implement it on one of the buttons on another site which can be found here: branchow.com/development/competition. I've included all the necessary files from the 1st link into the 2nd. However, when clicking the button to bring up the modal, it quickly fades and disappears.
Been trying to figure it out for the past couple of hours and haven't had any luck so far
Hoping someone could shine some light on the problem!
 
12:35 AM
@ThiefMaster I would like to borrow some of your blue diamond powers, ping me when and if you wish to help.
 
1:05 AM
on my way to bed, but feel free to ping me again later
 
@Sebastian woah, you're famous!
 
Guys, what stupid thing am I doing that causes this output pastebin.com/GSDewsy9 for this gulpfile: pastebin.com/Tw9CgENt
?
 
@SomeKittens hm?
 
1:27 AM
@Sebastian we love 6to5
 
@rlemon ah, thanks!
 
2:06 AM
Oh, we've got a celebrity!
Oh. I missed it.
 
@Sebastian HAVE MY BABIES.
 
He's gone buddy, it's ok.
there there
 
Haven't even used 6to5 yet if I'm honest.
 
2:55 AM
is there any generator like express generator that is a little more simplistic, I like it, but I don' always need the skeleton it provides
 
3:06 AM
Re: you talking about the farming space
 
hell yea
agri is big money and barely tapped with tech
 
is there a sneakily easy way in angular to display multiple icons, i.e $$$ based on a value
 
@phenomnomnominal i'll consider it
 
like value 2 would be $$, 3 would be $$$?
 
3:22 AM
@rodling throw a function to do that on $scope?
 
yea, thats not as sneaky haha, i thought of doing something like repeat, but wont work on a number.. needs a list
 
Node's built-in http server doesn't seem to identify Firefox's websocket request as proper upgrade request
Fuck
I wonder how any websocket ever worked with Firefox
 
does anybody install node js on dedicated server like bluehost ?
 
Probably because people use express or so
Reported March 2012, fixed December 2014
And hence only fixed in Node, not io.js
@copy At least there are no other bugs in Firefox
@copy You're right, other copy
 
3:42 AM
@copy \o/
@rlemon don't bother @copy
 
RCG
anyone around that knows some good info about the exec command for nodejs? I'm having an issue with one of the commands i'm trying to exec. stackoverflow.com/questions/28446168/…
 
@RCG 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.
 
@rlemon \o/
 
var exec = require('child_process').exec;

exec("ls", function puts(error, stdout, stderr) {
  // stuff
});
 
RCG
I can get the exec command to exec echo's and write to files but when I do the sed command it doesnt error, but it shows blank output and the file that it's supposed to write to doesn't show a file change.
 
3:54 AM
guys, what any token means after the method name in ES6
Example:
render(): any { ... }
 
Fluff to make JS more like a class-based language.
 
JS isn't a class-based langauge? But what about all those classes I took on JS!
 
6to5 renders it like this
var foo = {
  render(): any {}
}
 
Found it, those are artifacts from flow
 
"use strict";

var foo = {
  render: function render() {}
};
 
@monners JS really doesn't have classes. new and instanceof is just Javascript pretending to be Java. IMHO JS is best used without thinking in class (Object.create instead of new, isPrototypeOf instead of instnaceof).
 
@Sheepy I was being sarcastic :)
 
@monners Ok. Sadly, yes ES6 (and 7) is trying very hard (I think too hard) to make JS more class like...
 
4:22 AM
Welp, I bought it
 
user2620028
4:33 AM
Whats up guys
 
@SomeKittens The farm?
 
@monners KSP
 
user2620028
one of those sounded much less important than the other
 
@SomeKittens I still can't tell if you're talking about death or a financial exchange
 
KERBAL SPACE PROGRAM
 
user2620028
4:40 AM
I think he means Kerbal Space Program
 
@SomeKittens I KNOW! But did you buy the program, or did you crash your ship?
!!urban bought it
 
@monners bought-it A girl who either is/acts like/or dresses like a real [hooker-broad]
 
@monners Bought the program
 
Phew! Glad we got that sorted out
 
user2620028
clicks second rikudo's link in starred messages. Gets sad
 
5:00 AM
 
5:50 AM
How do we make a lib require-compatible?
or usable via require.js
Like say for e.g. loading kinetic.js in a require() construct?
 
6:16 AM
@deostroll I think change the object you write to from window to exports or something.
@all I asked this question yesterday, and it's gotten 1 DV and no comments. Anyone know what the problem is with the question? I'd like to fix it, and also get answers.
Why the downvote? This seems to be a well-researched question. — Scimonster 9 hours ago
 
RCG
how can you exec the sed command in nodejs? I've tried the shelljs npm and it only appears to handle SOME sed commands. when I enter the sed command that works for me in bash shell, it wont work when i try to bring it into nodejs with the 'exec' command or the 'shelljs' npm. Anyone able to look at my question? stackoverflow.com/questions/28446168/…
 
@RCG You're using exec correctly. It's your replacement that's the problem. ;) I just posted an answer there.
 
RCG
god i couldn't find anything about it anywhere. tried adding double slashes throughout the whole line too at one point!
you're a godsend :D
 
6:58 AM
I cant seem to understand why is it so hard to get the background style of an element in JS? jsfiddle.net/rdesai/cb8sbuho
 
Hi
all
I have string like var str= "207,201"; I want to spilt 207 and 201.
 
@RahulDesai Try with style = "background: url('http://www.brightlinkprep.com/wp-content/uploads/2014/04/sample.jpg')"
that is, add quotes to url param and remove the whitespace
oh nm, that just made devtools happy
too early for me, I'll get my coffee now
 
Awesome!
 
@SKM17 str.split(',')?
 
7:19 AM
@Scimonster I try this again its give same string
 
@SKM17 No, it should give an array.
Are you doing this in the browser's console?
 
!!> "207,201".split(",");
 
@Mr_Green ["207","201"]
 
@SKM17 ^
 
7:38 AM
Anyone here running AWS?
 
Hmm.
One of my hard drives is making the death rattle sound.
 
I am not good at spaceplanes
 
hi
everyone
 
@gayathri hey
after long time :D
 
hello :)
has anyone experience with l20n of Mozilla?
the internationalization library based on js and json?
 
7:58 AM
npm ERR! addLocal Could not install felixge/node-mysql
npm ERR! Error: ENOENT, stat 'felixge/node-mysql'
npm ERR! If you need help, you may report this log at:
does anybody know about this error when installing $ npm install felixge/node-mysql
 
@underscore I just tested and didn't get any errors.
 
when i'm installing github.com/felixge/node-mysql
i'mm installing this on my server via ssh
 
can javascript regex match this? four different hexadecimal digits
 
@Charly For example?
 
abcd is ok but 2003 is not
 
8:09 AM
[a-f]?
 
20031 is ok but abcccccccccc is not
basically at least 4 unique hex digits
any help is appreciated (even a "no")
 
I'm not great at regex, but i know it can be done without regex.
 
@Scimonster i know how to do it with if statements but it would be really long so thats why I want to try regex
 
How would it be long?
 
@Charly So, not that i know of, but it's possible someone more knowledgeable in regex than me will say yes.
 
8:15 AM
@RoelvanUden doesn't the statement have to check whether there's enough unique characters, and a string like abbbbbbbbbbbbcd will output true but take longer?
 
Regardless of it being your code or a regex, all characters have to be checked.
 
so it's pointless to do it in regex?
 
I'd do it normally, but I'm no regex expert either:
function isValid(value) {
  if (!/^[0-9a-f]+$/i.test(value)) return false;
  var map = {};
  for (var i = 0; i < value.length; i += 1) {
    var c = value.charAt(i);
    if (/^\d$/.test(c)) continue;
    if (map[c]) return false;
    map[c] = true;
  }
  return true;
}
 
@RoelvanUden thank you very much. This code is way shorter than what I had.
 
Oh, and I forgot to lower-case the characters. Do that too.
 
8:19 AM
nah all will be toLowerCase() -d before processing
 
morning
 
@Scimonster I read the rules again and it seems that oneboxing is encouraged, so
-1
Q: Unable to simulate a POST request -- not getting the correct response

ScimonsterI am trying to programmatically submit a form (POST request) on a remote site from a command-line NodeJS script and scrape the return data. The remote form is here. When i submit it through the browser, it first goes to the page itself (specified in the <form action>), which returns a 302 statu...

 
@RoelvanUden but "20003" isn't supposed to return true...
 
can anyone help me with l20n?
 
8:34 AM
@Charly Why not?
 
@RoelvanUden there's only 3 unique characters: 2,0,3
 
So change the logic to accommodate that. It's pretty easy now.
 
I will... (try to)
 
@Mr_Green its working
 
@SKM17 good
 
8:42 AM
what mysql dependency is good with node js?
 
@underscore I'd use knexjs.org or bookshelfjs.org. The adapter they use is mysql (how surprising). I'm sure that's the one by the awesome felixge (that you were installing earlier).
 
@Scimonster mmm...changing the library code? Is that what you are getting at? I don't think that is the correct way...
 
@RoelvanUden i installed knexjs
how can i execute the sql ?
 
Read the documentation. It does wonders.
 
8:55 AM
just
knex.select('title', 'author', 'year').from('books')
right?
 
Yes, after you've set up the connection and pooling of course.
 
var app = require('express')();
var http = require('http').Server(app);
var io = require('socket.io')(http);

var knex = require('knex')({
  client: 'mysql',
  connection: {
    host     : '127.0.0.1',
    user     : 'xxx',
    password : 'xxxx',
    database : 'xxxxx'
  },
  pool: {
    min: 0,
    max: 7
  }
});



http.listen(2122, function(){
  console.log(knex.select().from('branches'));
});
but this console.log showing me an object
 
knex.select().from('branches').then(function(result) {
  console.log(result);
});
 
Thanks
 
9:14 AM
What is the process.env PATH like on linux? I want to run a child_process.exec with npm modules in the path and I can do that with Path on Windows but I have no idea what it would be like on Linux
 
9:25 AM
Got it. Nevermind :-)
 
9:37 AM
guys, ned your help... I am in a job position with good money but im bored like hell... the projects are boring, i cant learn anything new, my boss is an asshole - but im very safe here 3month quitting time etc. etc.
But I have a job offer from a firm in which I am my own boss, I will decide my projects (at least the most of them), my envoirement, my own room and more money (6k / year more) etc. - but the firm from the job offer is more "dangerous", so it's nearly a start up (3 years) with only 8 employees... any sugestions?
 
@RoelvanUden as someone who used linq - how are node ORMs?
@Kovu move, being a startup is an advantage not a disadvantage.
 
@BenjaminGruenbaum Im a little scared about the whole "only 1 developer" thing...
 
Only one developer?
That's only good if you have very strong self discipline
 
8 IT network guys which work for the german city mostly
and they need a developer because they see much improvement-possibilitys when they have one
 
@Kovu if I were you I'd interview a lot more.
 
9:46 AM
@BenjaminGruenbaum Extremely basic and limited, but still a better abstraction over writing raw SQL statements. The same applies to almost every ecosystem though, including PHP and so forth. Really limited compared to the power of Linq expressions.
 
@Kovu You just have an old job and a single offer. You have no idea what your worth is. Go and find out.
 
Hello All
the dataType application/x-comma-separated-values is fine?
 
@RoelvanUden that's what I thought, thanks. I wonder if this can be fixed. I wonder if a tool like 6to5 or even just acorn can provide the abstractions needed for a LINQ expression (cc @Sebastian )
 
doesnt seems to be executing success callback
 
@techie_28 google it. I just did and found results - I'll give you a tip - that dataType string is called a mime type.
 
9:48 AM
@BenjaminGruenbaum in fact I interview a lot, I had 10 interviews in 4 weeks...
3 firms declined me
I dicides to decline 2 firms on my own
I get 2 job offers - one is the same boring project as I have now, one is the IT-Network firm i told about
The rest I wait for answers
 
@BenjaminGruenbaum I'd imagine it was possible. If you can determine the types, that is, and then you should be able to map that to the defined models and relationships to build queries that include all the foreign relationships and so forth. I don't think many people know the power of that, though, unless they did C#, so they don't "miss" it and don't "need" it I guess.
 
Hello, can anyone help with issue: stackoverflow.com/questions/28437473/…
 
I do not have mention "accepts" right?It depends on the dataType
I do not have mention "accepts" right?It depends on the dataType
 
Hii.. Need help in angularjs
Please check it
http://stackoverflow.com/questions/28451399/set-model-is-null-in-directive-in-angularjs
 
@BenjaminGruenbaum text/csv also doesnt help me
I had tried that before
 
10:04 AM
@AmitKumar which modelvalue exactly?
empNmae ?
 
SelectBOX ng-model should be null
@RahulDesai: yes
 
Im using promises .then @BenjaminGruenbaum
dataType = text is working
 
@techie_28 I googled it and found the result.
@RoelvanUden yeah, but we're already talking about optimizations in 6to5 based on type.
 
@AmitKumar Please check out my answer.
 
10:10 AM
@Kovu in that case I take that back - this is exactly what you should be doing.
 
@BenjaminGruenbaum you mean take the offer?
 
@Kovu no, I mean the part telling you to interview more since you're already doing that. I'd take the offer but I'd wait for other offers too.
 
Okay, so take the offer but with the option to take better offers soon? wouldnt it be unfair for the new firm?
 
@BenjaminGruenbaum If 6to5 ever gets mature support for types, I'll be all over it. :P
Until then, TS for the win.
 
It has mature support for types - the problem is facebook not compiling flow for winodws.
6to5 can and will utilize flow :D
 
10:16 AM
@AmitKumar Did you try it?
 
@BenjaminGruenbaum Yeah I've checked out flow, but it didn't strike me as a mature implementation, though. I'm not saying the checker is bad, it seemed pretty reasonable and pretty accurate; possibly better than TS. It adds new syntax, though, but without any kind of idea or plan for tooling. That's bad, really, really bad. In this day and age and I feel that tooling and libraries make or break languages; not the basic concept. On that front, TS is unrivaled by AS or flow.
 
@RoelvanUden I humbly disagree - flowtype is a single component in a huge ecosystem facebook built including but not limited to regenerator, jsx, react tooling and so on.
the flux architecture, tons of react components etc
ImmutableJS (collections), browser extensions for development, unit test frameworks
 
I'm not saying that's bad; just that flow isn't interesting due to (lack of) tooling.
If I'm considering flow I honestly don't care what else the people behind it made.
 
Tooling is a big issue I agree.
 
Hi all
 
10:21 AM
@nani1216 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.
 
Thank you @CapricaSix
 
I like it when people are polite towards machines.
 
yeah but they get sad when they don't reply.. which changes their attitude forever
 
I'm trying to implement a circular navigation buttons using html5 canvas. i'm dealing with applying 3d effect to the edge of the buttons...
 
@RoelvanUden Then this must upset you? youtu.be/M8YjvHYbZ9w?t=24s :)
 
10:26 AM
 
0
Q: HTML5 Canvas drawing shapes with 3d edges

nani1216 I'm trying to create buttons as shown in the image using html canvas I tried linear and radial gradient effects but i'm unable to get the sharp edges as show in the image. The button should look like 3d object. There is a shining effect on top right (arrow) bottom right edge effect for green b...

 
@ivarni Very much so. I am against violent actions against animals; robotic or not does not matter. Kill that guy! Violence against people can be warranted!
 
I googled and it gave me text/csv which did not work,supplying text worked @BenjaminGruenbaum
 
where do I post a really useful code snippet/idea for javascript?
 
@tonyloban 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.
 
10:39 AM
@nani1216 are you also using kineticjs plugin?
@tonyloban gist/github will be best.
please share the link after posting it.. :)
 
@MR_Green never used it before or anything, mind explaining like I'm 5?
@Mr_Green mind explaining like I'm 5? never used git or no idea what it is
 
@tonyloban I suck in explaining things. but still I will try..
gist is used to share code
github is used to share projects
In any programming language.
Not only just code but also articles or any content.
Create a account and keep everything which you love in one place for easy access
@tonyloban did you understand my reference?
 
A little experience sharing: I began a tooling chain with Grunt. After going through tons of configuration setting (~2 weeks use), it became unwieldy and I switched to Gulp. It was better; the code approach is clearer (~4 weeks use). However, streams are awkward (e.g. read-only files), prone to errors, and Gulp dependencies are often out of date. I removed Gulp code and now have a little self-written task runner. Tip: Use dependencies directly, abstractions suck and make life difficult.
 
@RoelvanUden The funny thing is that we already learned this years ago, yet seem hell-bent on repeating our errors (I'm a grunt user even though I know it's stupid)
 
10:55 AM
@Mr_Green Yes, makes sense. Thanks (:
 
who wants to buy me one
also hi
 
@ivarni I didn't learn this lesson until now :-P
 
@RoelvanUden It could be my history with Java and the abomination that is maven that taught me this earlier :)
 
I thought Maven was good
 
If you like reading 2000 lines of XML to reason about your build-process it's not too bad
 
11:02 AM
Here is the link: https://gist.github.com/antonlobanovskiy/c68c399d79c88fcfcdda

Pretty much, I wanted to see what my friend replied to in one of those viral videos/pictures on facebook. It shows on mobile what the friend said, on pc, it didn't, but either way, going through my steps will make searching for where they replied MUCH easier instead of scrolling down and clicking view more comments
 
This is in the context of comparing it to Grunt/Gulp's problems though. As a dependency manager it isn't too bad. As a build tool.. just no... it will hurt at some point.
 
especially when there's thousands and thousands of comments
 
@ivarni Are you talking about maven?
Because it sure sounds like maven :P
 
@SecondRikudo yes, indeed :)
 
Yeah maven sucks.
 
11:19 AM
@RoelvanUden that's what I've been saying the whole time in this room and no one is listening :P
That tools like grunt/gulp don't really solve your problems very well compared to hand written task runners since you have really strong concurrency control constructs in JS
 
Aye. Besides, my task files are so much simpler now.
And the basic task runner is what, 20 loc?
 
hi guys
is there any way to append multiple script tag in head dynamically
 
hey all, anyone got any MongoDB experience?
 
!!welcome Vade
 
@Vade 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.
 
11:29 AM
@John "Yes."
 
How do I use .replace() to replace special characters?
 
You're using val wrong. Read the API docs.
 
So, have you heard about "React Canvas"?
 
Yeah already starred, very nice idea.
Actually surprisingly super useful because we literally got a development task yesterday that required rendering HTML to canvas
 
11:42 AM
Fun :D
 
Does that mean DOM is dying?
 
I hope so
 
interesting
 
Also, the DOM is all the APIs not just rendering, but rendering to canvas if done right could be so much funner. If done right that is.
Canvas is also DOM so there's that - it's just keeping the DOM as simple as possible
 
I think canvas is just a texture with some state
 
11:44 AM
Yeah, but it's specified at the DOM API level.
 
Oh yes, I just mean that there's nothing inherently dom-ish about it
 
Immutable canvas should actually perform pretty well :D You queue the write operations and then figure out what you didn't have to do before rendering in retrospect - so it's just a queue of transformations that gets added to.
I'm sure someone like @Raynos had a shot at it before.
 
especially when you consider the webGL context
 
@Mr_Green ah, my bad
 
11:46 AM
@BenjaminGruenbaum I'm going to do it in Hate.
 
thanks!
 
it's just drawcall batching
 
@RahulDesai by seeing your fiddle.. I got confused and did many nasty things without seeing benjamins comment.. :D
 
one of my latest Haskell examples posted here was about that actually
 
@Mr_Green :D I just completely forgot about .text()
 
11:47 AM
a fun idea no less. I was reluctant to go in that direction but so far pure FP approach to rendering seems quite ok
 
@SecondRikudo can know tell me how can we?
 
@John Nope, you'll have to tell us more about what you're trying to do.
Right now "Yes" is the only answer I can give you.
 
Hey guys! I've a rather specific question about Flot.js, using the JUMFlot.js plugin.
 
@MicheldeNijs 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.
 
I want to append some JavaScript in head tag when page loads completely
 
11:54 AM
@John So create some script elemetns, fill them with code and append to the head.
 
I got this example
`var head = document.getElementsByTagName('head')[0];`
` var script = document.createElement('script');
script.type = 'text/javascript';
script.src = http://www.example.com/includes/js/jquery.js';
head.appendChild(script);`
 
@John Yeah, and?
@John Paste, CTRL+K, enter
 
but its just for one source
this is not the way it will fit in programming
 
@John Do you understand what each line does in that example?
 
I want it to happen in loop
yes
 
11:57 AM
@John So where is the problem??
 
I just wanted to change script.src and not each and every
 
@John You aren't making sense. Slow down and try to explain exactly the situation you're in.
 
okay lets go one by one
when page loads completely
at the end of the footer I wall call this function to load some js files
 
He wants to include multiple javascript resources dynamically at run-time, with javascript. He haz ze codez, but he only wants to modify the "src" attribute and not repeat all the other crap around it every time in a loop
..I'm your agent.... for today....
 
these files will be attached in head tag dynamically
so we have to change only script.src because other other 3 will be constant
so my query is how can I loop through script.src so that all my script tags will be append one by one
 
12:01 PM
@John Okay, do you know the srcs of the files you want to load in advance?
 
yup
 
Great
 
@John the most simple and convenient way would be to create a simple function, which does exactly what you posted above. As Argument for that function, you pass in the source to the js-file and replace that within that function every time you call it.
 
Create an array of all the srcs you want, and use arr.forEach() to loop over it.
Putting it into a function like @jAndy says is also helpful
function addScript(src) {
    // Fill in here!
}
 
@John To be honest if the script location is predetermined it is often simpler - and faster - to put them as external linked <script> at the end of <body>
 
12:02 PM
Then you just call the function with different sources
 
technically, that creates a new independent script-element every time the function gets called, but that is not a problem at all. Again technically, you really could do it all with the same script-element, but .. I don't see the reason here to do that.
 
@BartekBanachewicz Again :(
 
@jAndy okay thanks
lets see if that works
 
I am giving really bad answers today. :-/
 
@BartekBanachewicz yeah rendering is one thing pure FP +laziness can work in since you aggregate changes instead of actually rendering until you have to.
Carmack has some good stuff on that
 
12:13 PM
@Sheepy thanks I m surprised by your honesty
 
Well, Less must have the worst designed API ever. What's the fucking point of accepting ONLY a string input to render, while allowing import statements to be resolved if you also give the file name. Why can't I render from a file directly? Shitty designs, geez, think for a minute there. /rage
 
12:33 PM
I just read Object.observe, which bring me to the question, is an angular like two way data binding with Object.observe?
 
Was there a question in that? Or a completed sentence? ^
 
question
"which bring me to the question"
 
You're missing some verbs to have that sentence make sense.
 
Ow.
 
12:51 PM
@argentum47 Are you trying to ask if angular bindings work the same way as (or make us of) Object.observe? In that case the answer is no, Angular (1.3) uses dirty checking
 

« first day (1579 days earlier)      last day (3383 days later) »