« first day (1725 days earlier)      last day (3213 days later) » 

12:01 AM
which is what that website uses
 
winforms, at least, has value. It wraps old windows controls.
webforms just creates horribleness out of nothing
 
the tried and true microsoft way
then make it enterprise
 
microsoft has done it all ways. and invented a few of them
 
and made plenty of money along the way
 
12:12 AM
reminds me that there's a phenomenal documentary on super smash brothers youtube.com/watch?v=jX9hbbA-WP4
highly recommend the watch if you have an extra 4 hours to kill
 
12:46 AM
Wow, JS room has been inactive for 33 minutes.
 
JavaScript is dead
Start using Python today
 
0
Q: Undefined is not a function in AngularJS

DemCodeLinesI have been following this tutorial: https://thinkster.io/mean-stack-tutorial/ and I have come across a strange issue. The upvote button is not working as intended. Clicking on it does not do anything. Instead, in the Chrome console, it shows a 500 error. Here are the files in question: angula...

 
Or there's nothing interesting to talk about because no new framework was released in 10 days
 
@DemCodeLines but index.js doesn't have a 59th line
@DemCodeLines either way, people might not like that question b/c it's a code dump/the code is on pastebin
 
-1
Q: Undefined is not a function in AngularJS

DemCodeLinesI have been following this tutorial: https://thinkster.io/mean-stack-tutorial/ and I have come across a strange issue. The upvote button is not working as intended. Clicking on it does not do anything. Instead, in the Chrome console, it shows a 500 error. Here are the files in question: angula...

 
12:53 AM
There actually seem to be some people who say cool whip like Stewie does
 
Lol, got -2, but just one person decided to actually comment.
 
11 mins ago, by royhowie
@DemCodeLines either way, people might not like that question b/c it's a code dump/the code is on pastebin
 
@copy If I don't supply the code, I'll get downvoted because "you didn't show us any code!"
 
Good sign that your code isn't a good fit for SO
 
@copy I understand that it's generally recommended that I cut out everything else and just show a small piece of code where the error is, but sometimes, you can't really do that.
 
1:07 AM
Yep, but with a big pile of code it's easier for you to step through the code to find the bug then for the community to spot the problem manually
 
True. I have been working with the Chrome debugger to see where the problem is, but without any luck
 
@DemCodeLines Finding uncaught exceptions in the Chrome debugger is a tonne easier if you hit the "Pause on exceptions" button. It's a pause symbol in a stop sign on the Sources tab.
 
1:27 AM
check if req.post.upvote is defined
I bet it isn't
no money
but I bet it isn't :P
 
@rlemon Over here?
// Upvote route for particular post
router.put('/posts/:post/upvote', function(req, res, next) {
  req.post.upvote(function(err, post){
    if (err) { console.log(err); return next(err); }

    res.json(post);
  });
});
 
yes
seems to be relevant code.
12th column..
 
m.reddit.com seems to be written entirely in javascript
Why would you write a mobile site in javascript
 
console.log(req.post.upvote); before the function call.
 
Thing barely runs on my phone
 
Oh good, not just me.
 
@DemCodeLines Hover over "name" in that throw call to see what it's complaining about.
 
If you switch to compact view it's pretty good. Except if you hit back, it flashes and shows the same page again, then some 5 seconds later the previous page loads
Everything's just super delayed
 
looks like a bit of bloat + poorly optimized rendering in react
according to that thread, I mean.
 
Yeah I'm still skimming it. This guy really went deep
Neat
 
1:37 AM
@rlemon it doesn't even log anything:
// Upvote route for particular post
router.put('/posts/:post/upvote', function(req, res, next) {
  console.log(req.post.upvote);
  req.post.upvote(function(err, post){
    if (err) { console.log(err); return next(err); }
    res.json(post);
  });
});
 
console.log('here', req.post.upvote);
just make sure
 
// Upvote route for particular post
router.put('/posts/:post/upvote', function(req, res, next) {
  console.log('here', req.post.upvote);
  req.post.upvote(function(err, post){
    if (err) { console.log(err); return next(err); }
    res.json(post);
  });
});
is not printing anything either
I wish there was a way to put this in a fiddle.
 
MLM
Anybody know of a library that can add some text on top of an existing PDF file? pdfkit is nice but can't read in existing pdf's. pdf.js is only for viewing pdf's
 
@rlemon It seems this where everything is breaking: return $http.put('/posts/' + post._id + '/upvote')
Keeps throwing 500
 
1:55 AM
Hi,

How to Push PHP JSon Result into Jquery Array?
 
@Mediasoft 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.
 
Have any of you by chance ever worked with FedEx web services?
 
FUCK FEDEX
Sorry
They never ring my doorbell, they just leave the packing slip
 
Is that a yes?
 
And their pickup thing is only open for 45 minutes monday - friday
 
1:57 AM
because fuck FedEx
 
and it's 40 minutes away
and I don't have a car
I shit you not. 5:00 - 5:45
 
Well, FedEx web services are worse
 
Guuh
How can they possibly be worse
 
Think "no documentation"
 
Is anybody know How to Push PHP JSon Result into Jquery Array?
 
1:58 AM
Well, there's a 1000-page PDF full of everything that assumes prior knowledge
 
TIL a chat post can give me leukemia
 
most of which is not available it seems
 
@Mediasoft JSON is already a javascript object
 
Anyone else want to take a try on my question?
 
I guess no one knows anything about this
 
1:59 AM
Yes,
 
Which kind of makes me glad
 
Yeah I avoid fedex like the plague, sorry
 
but how i can add in javascript array ?
 
because it's nice to see people not suffering
 
What do you want to add to the array?
The single object?
 
2:00 AM
1
Q: How to Push PHP JSon Result into Jquery Array?

MediasoftI am actually Working on JQuery Vector Map and i generating Data from PHP in json format and now i want to add it in Jquery Array to show at Mouse Hover on Vector Map. below is the Code i am using but it is not working: !function ($) { $(function(){ //jvectormap data var UsersDat...

please visit this link
i post my question there
 
I'll take that as a no.
 
@DemCodeLines I'll try
 
-2
Q: Undefined is not a function in AngularJS

DemCodeLinesI have been following this tutorial: https://thinkster.io/mean-stack-tutorial/ and I have come across a strange issue. The upvote button is not working as intended. Clicking on it does not do anything. Instead, in the Chrome console, it shows a 500 error. Here are the files in question: angula...

 
@Mediasoft userData = res I assume
instead of push
Just use the object
 
@MLM Ghostscript can do it.
 
2:04 AM
how ?
 
@Mediasoft replace userData.push(res) with userData = res ?
 
but it gives only the Last Record
["AF:1", "DZ:1", "AS:2", "AD:0", "AO:4", "AI:2", "AQ:0", "AG:0", "AR:1"]
 
@DemCodeLines Add console.log(req.post) before line 59
 
when i am printing on Console this is result coming
 
MLM
@Luggage Thanks, I am trying to find some docs or example for adding/editing a pdf
 
2:06 AM
@Mediasoft Printing what to the console?
 
Note that Ghostscript is AGPL.
 
@Cereal
@Cereal i am printing the Result
 
@Cereal It doesn't print anything in the log
 
@DemCodeLines wat
 
no kidding
 
2:08 AM
Nothing
Zero
 
I'll show a screenshot
Except for the error
 
well log req then ._.
@Mediasoft So the JSON you're recieving is that array.?
Do you control the JSON that is being returned?
 
Clicking that like button only throws that error in the log.
 
....lol
you need to check logs on the server :P
 
awkward
 
2:12 AM
Oh, story time
I'm in the US, so I went to ponarosa (sp)
Anyway, in the time I was there, I saw 3 people on oxygen
 
What's ponarosa?
 
1 old, fat lady in a cheetah print shirt with sparkle leggings with platinum blonde hair
!!google pondarosa
 
._.
 
ohh, pondarosa. I didn't know those still existed
 
2:13 AM
ponderosa!
 
1 message moved to Trash can
@Mediasoft Please don't post unformatted code - hit Ctrl+K before sending, and see the faq. For posting large code blocks, use a paste site like gist.github.com, hastebin.com or pastie.org
 
It was disgusting.
Like the food was okay
it was 11 dollars for literally anything forever
all you can eat buffet, where the buffet is anything ever made
 
@rlemon Running on my computer. Don't know where the logs are.
 
That's how you know it's quality.
 
[
{
code: "AF",
total: 1
},
{
code: "DZ",
total: 1
},
{
code: "AS",
total: 2
}
]
 
2:14 AM
But the amount of food people were eating actually made me sick
 
@DemCodeLines how are you starting node?
 
Some lady walked past me with 3 plates of fried chicken and mashed potatoes
Also they have sizes bigger than XXXL here
 
npm start from cmd
 
AND THE WAL-MART WAS HUGE
 
just node app.js
 
2:15 AM
You don't go to an $11 all-you can eat buffet when you want a small plate
 
logs come in the terminal
 
good looking girls though
 
???
 
@Mediasoft hint: you don't want an array
you want an object
 
PUT /posts/559b0a96f53df7e010a16d8d/upvote 500 4.058 ms - 1816
PUT /posts/559b0a96f53df7e010a16d8d/upvote 500 4.049 ms - 1816
 
2:15 AM
Where do you live normally?
 
@Mediasoft Do you control the JSON being returned from the server?
@Luggage New brunswick
 
not the one in Pennsylvania, I imagine..
 
Canada!
 
@DemCodeLines if you're not seeing the console.logs in the terminal you're not running the functions that have them included.
 
!!wiki new brunswick, canada
 
2:16 AM
@Cereal how to do that ?
 
@Cereal That didn't make much sense. Use the !!/help command to learn more.
 
ah.
 
New Brunswick (French: Nouveau-Brunswick; pronounced: [nu.vo.bʁœn.swik], Quebec French pronunciation: [nu.vo.bʁɔn.zwɪk]) is one of Canada's three Maritime provinces and is constitutionally bilingual (English–French). It was created as a result of the partitioning of the British Colony of Nova Scotia in 1784. Fredericton is the capital, Moncton is the largest metropolitan (CMA) area and Saint John is the most populous city. In the 2011 nationwide census, Statistics Canada estimated the provincial population to have been 751,171. The majority of the population is English-speaking, but there is also...
 
@rlemon Problem is, the function was working fine until a few steps ago in the tutorial...
 
@Cereal bcoz above i just post the PHP Json result
@Cereal
[
{
code: "AF",
total: 1
},
{
code: "DZ",
total: 1
},
{
code: "AS",
total: 2
}
]
 
2:17 AM
@Mediasoft I don't know how else to word this. Uhh.. Did you write the php file?
 
yes i do write
 
var data = {};
json.forEach(function(item) {
  if( !data[item.code] ) data[item.code] = item.total;
  else data[item.code] += item.total;
});
@Cereal he wants this
 
I think he should rewrite his json in the first place ._.
 
I'm not answering any more questions about it
:D
glhf
 
Like
 
2:19 AM
What the heck, it just started working.
 
{ "AF": 1, "AS": 2 } or whatever
 
I restarted the node server and it decided to start upvoting.
sigh
 
@DemCodeLines Restarting the server is a wonderful tool
 
I wasted 2 hours when all I had to was restart the server.
 
2:20 AM
yes i need answer in curly brackets
 
@Mediasoft Then return the json in curly brackets =p
 
@Cereal

var UsersData = [];
        $.getJSON('vec_map.php', function(data)
        {
            $.each(data, function(key, val)
            {
                var res = val.code + ":" + val.total;
                //UsersData.push(res);
                UsersData = res;
            });
            console.log(UsersData);
        });
 
No I mean in the php file
 
@cereal this is my code
 
you need to learn the difference between an object (key value store) and an array in js
you seem to be confused.
 
2:23 AM
@cereal

print_r(json_encode($arr));
this is what i am printing. but the problem is how i can access all the result in Jquery side
as i mention the above code
 
:takes off clothes and dances because obviously my invisibility skills have kicked in:
 
test.rs:9:1: 13:2 error: type parameter `T` must be used as the type parameter for some local type (e.g. `MyStruct<T>`); only traits defined in the current crate can be implemented for a type parameter [E0210]
 
Change

[
{
code: "AF",
total: 1
},
{
code: "DZ",
total: 1
},
{
code: "AS",
total: 2
}
]

to
{
"AF":1
"DZ": 1,
"AS": 2
}
 
fuck me oh wait this language is already doing it
 
!!am I shadowbanned?
 
2:28 AM
@rlemon Absolutely not
 
I laughed
I ordered an alienware the other week on their payment plan. My account number still isn't recognized. Assume it won't work til everything is shipped, but man am I going to be annoyed if it doesn't by the time the first payment is due
almost had a stroke
Computer reads 10:45
Hotel clock reads 11:20
 
2:46 AM
it is 10:45
 
It is indeed
 
@rlemon Can Caprica even shadowban?
 
no I was making a joke
dude vamped, I gave answer, not on a silver platter (almost), got ignored hard core.
 
Everyone just wants the finished product without learning how to make it
grumble
 
vaaaaamps
@Cereal Including my boss!
oh wait, that makes sense
 
2:52 AM
My gpu isn't going to fit in the graphics amplifier I ordered. NCIX was like "no" when I asked if I could swap it for an evga card. Wonder if I can sand it down..
by not fit, I mean it doesn't close all the way
I just wanted to complain about that
Ou, 1111 points
 
What the heck. Getting that problem again with another piece of code.
restarting the server hasn't helped yet.
 
the undefined problem?
Just means you're calling a function that doesn't exist.
 
Right, it's on a register form now.
Console.log doesn't work the way it didn't work previously.
 
server loggg
 
3:08 AM
Literally all the server says regarding register: POST /register 500 6.204 ms - 1854
Interestingly, it happens at routes\index.js:108:8, which is: user. setPassword(req.body.password);
 
setPassword doesn't exist
 
It does!!
var User = mongoose.model('User');
var user = new User();
user.username = req.body.username;
user.setPassword(req.body.password);
 
what's the exact error
 
/me scoffs at un-hashed password
 
/me scoffs at user accounts in general
 
3:13 AM
If you're not using TypeScript with Observables on top of React, I don't know what you're doing
 
@SomeKittens TypeScript is addictive as aye
 
@SomeKittens I'm literally following a tutorial trying to learn the MEAN stack
 
You're not a rockstar dev if you're not using TypeScript with Observables on top of React utilizing ECMAScript 6 lambda functions
something something buzzwords
 
@phenomnomnominal Is "Addictive as aye" a kiwi phrase?
@Cereal TypeScript has ES6 features baked in drops mic
 
addictive as (something that is very addictive), aye (do you agree?).
 
3:15 AM
@Cereal here:
undefined is not a function

TypeError: undefined is not a function
    at C:\Linked\linked\routes\index.js:108:8
    at Layer.handle [as handle_request] (C:\Linked\linked\node_modules\express\lib\router\layer.js:95:5)
    at next (C:\Linked\linked\node_modules\express\lib\router\route.js:131:13)
    at Route.dispatch (C:\Linked\linked\node_modules\express\lib\router\route.js:112:3)
    at Layer.handle [as handle_request] (C:\Linked\linked\node_modules\express\lib\router\layer.js:95:5)
    at C:\Linked\linked\node_modules\express\lib\router\index.js:277:22
Lines 100-115:
// Creates a user given a username and password
router.post('/register', function(req, res, next){
  if(!req.body.username || !req.body.password){
    return res.status(400).json({message: 'Please fill out all fields'});
  }

  var user = new User();
  user.username = req.body.username;
  user.setPassword(req.body.password);

  user.save(function (err){
    if(err){ return next(err); }

    return res.json({token: user.generateJWT()})
  });
});
 
@phenomnomnominal aye.
 
I'm currently building an ETL system with said TS/Observables
 
@DemCodeLines dude stop.
 
HAMMERTIME!
 
3:17 AM
ok ok sorry
 
@SomeKittens sounds fun/hard
 
@phenomnomnominal I'm completely over my head
 
!!hi
 
@DemCodeLines Hello
 
@SomeKittens best place to be
 
3:17 AM
haven't been this way in ages
 
at least Benji can help if you need it haha
 
I'm struggling the most with putting together the ETL
probably because that's the one thing that none of my friends do (and so I can't pester them)
 
oh right, does the reactive stuff help or make it harder?
 
Still can't figure it out. This is nonsense.
 
3:33 AM
@phenomnomnominal I'm not sure yet
current struggle is registering dependencies
the whole "Observable" model doesn't lend itself too well to that
 
3:52 AM
Quick Question... call all the old Function.prototype = {} be converted using the new HTML5 Class structure?
Thats kinda nice... :)
 
4:23 AM
I still haven't figured this out...*sigh*
 
how we can hide the API Link from Browser Console ?
 
2 messages moved to Trash can
!!welcome Mediasoft
 
@Mediasoft 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.
 
@Mediasoft make it private. write a get function to get the url
 
@Mr_Green they will still be able to see it when a request is made
 
4:37 AM
but it will not be accessed using console right?
 
but then they can just copy and paste it...
 
yeah @Mediasoft check above message
 
@Mr_Green which message ?
 
2 mins ago, by phenomnomnominal
but then they can just copy and paste it...
 
@Mr_Green After getting the URL then what need to do ?
@Mr_Green i have this Command in Javascript but it is not working

console.log = console.error = console.info = console.debug = console.warn = console.trace = console.dir = console.dirxml = console.group = console.groupEnd = console.time =    console.timeEnd = console.assert = console.profile = function() {};
 
4:45 AM
@Mediasoft at least your question is pure JS, my thing is AngularJS and defies logic.
 
@DemCodeLines Do u have the same question as mine ?
 
you guys should get a private room and talk about your problems
 
@Mediasoft No.
 
Not talking about it won't help
 
@phenomnomnominal Ehh...I often ask questions here, but I end up solving 80% of them myself.
 
4:47 AM
@phenomnomnominal what kind private chat? we are here to help each other
 
Hi all, I'm trying to use this github.com/TFaga/generator-react-reflux yeoman generator to try out but it seems erroneous or I'm doing sth wrong. I'm installing it by npm install -g generator-react-reflux then in the app directory I try: yo react-reflux
"You don't seem to have a generator with the name react-reflux installed" is what I get
 
@BenjaminGruenbaum: Just added unclosed bracket ], which is not covered in ES6 specs, as far as I can see
Non-quantifier sequences /{r}/ is an extension, but it is already covered by the annex in ES6
 
@Ekin This might be a silly question but I assume you didn't get any errors when running npm install initially?
 
Nope, everything was all okay @ivarni :/ weird
 
I just ran the exact same sequence of commands as instructed on their github page and it worked. I'm on node 0.12.4, npm 2.10.1. Very hard to tell what's wrong without knowing more details
If you find the global node-modules folder, is the generator there?
 
5:09 AM
I'm on node 0.12.6, npm 2.11.2
Will check now
Can't find it in node_modules, but I didn't get any errors
 
maybe you forgot the -g flag when you installed the generator?
 
hey all. 'Merica
 
nope I didn't, just checked and all the commands are equal to the ones on the github page
 
@Ekin Then I'm all out of ideas, but if you didn't find a generator-react-reflux folder in the global node_modules folder then that's where I'd start looking
 
Yep, thanks a lot @ivarni
 
5:18 AM
@Ekin probably a sudo issue. I had that happen before. I bet if you run sudo yo then you'll see the generator. I had to reinstall npm I think to fix permissions
or I guess sudo yo react-reflux
 
lol yeah I did sudo yo and it was there @taco thanks!
 
np
It's a pain after a while because I forgot. so i think i reinstalled npm via homebrew or something. Or maybe you could just remove it and reinstall it
or leave it and be happy and lazy. best combo
@Ekin how is React / Reflux
 
Didn't try it yet, that was my purpose though. After I bumped into this: ochronus.com/react-reflux-example
 
Okay. I setup an Angular-React Directive seed, but haven't gotten back to using it yet
 
5:35 AM
Redux also looks pretty cool, t.co/kkH88DUMgx [video]
 
JS community moves way too fast for me! They improve shit way too quickly :p
 
they improve shit?
 
yeah, you know. community turds
 
ew
 
Grunt -> Gulp. nodejs -> io.js. Asm.js -> WebAssembly
I don't have enough time to learn everything quickly enough :d
 
5:41 AM
WebAssembly replaces asm? I thought it was more of an alternative to browserify/require
 
it's neither
 
oh no wait, that's webpack
 
it's a binary target for the web
 
I get coffee now
 
I assumed it was like Asm.js for all browsers
 
asm.js is for all browsers
 
note to self, don't discuss buzzwords before 8 am :)
 
asm.js can just be optimized specially, which not all browsers do yet
 
oh ok. I read articles like this that said all browsers didn't support it yet, but it looks like I missed that key point infoq.com/news/2015/02/ie-chrome-asmjs
 
Meowrning
 
5:46 AM
Merica'ning.
Anybody else miss the first 20 minutes of the World Cup? I was in a car on the way to the bar.
Saw a facebook update saying USA had scored two goals, and by the time we sat down, it was at 4...
 
I missed all of it, and I'm not even sure which sport you're talking about :)
 
Football (Soccer)
Women's championship - World Cup
 
Ah
Doesn't get much coverage over here I guess
 
fencing is hard
morning btw
 
fencing is stupid, you get points for basically everything
 
5:50 AM
Duh it's almost 3am here and I have 15+ tabs of interesting stuff to keep me awake for at least 5 hrs. Yep, morning to you all
 
Which countries are you from?
 
3AM? Are you in the Atlantic ocean?
I'm in ATL and it's almost 2 AM here :p
@ivarni heh, gonna tell my friend who fences that
 
It's 13:52 in China.
 
Yep, 100mts to south atlantic
Uruguay
and it's effing cold
 
America has approved gay marriage. How fantastic.
 
5:54 AM
Yep. DJ'ing friends party who are gay this month
 
Yeah I heard it's the law of land now, cool stuff happenning there.
 
@taco They've a button on the tip of the "sword" if that's pressed they get a point. Doesn't matter if you hit the other person in the face or the pinky finger
 
Although, I now see people flying the "rebel" flag alot more. Huge ones on trucks.
 
@taco What does "Huge ones on trucks." mean?
 
@ZhengquanBai They are putting huge flags on trucks
 
5:56 AM
@taco Okay, I got it.
 
I'm gay. China still has a long way to go to embrace gay marriage.
 
I'm sorry about that. It makes me a bit sad when people tell me that
 

« first day (1725 days earlier)      last day (3213 days later) »