« first day (1503 days earlier)      last day (3446 days later) » 

12:00 PM
Yes I read it, it's entirely retarded, but people are retarded, what you gonna do about it?
 
@phenomnomnominal you can for example not make shitty products.
that's one thing you can do.
 
It's their own fault for buying it. If it made the people who made it more money than it cost to develop, it's successful.
 
...
I don't think you'll ever get it.
 
Of course I get it.
You want to live in a world of academic perfection.
 
what has academia to do with anything? I absolutely hate my university and it's far from perfect.
 
12:03 PM
I'm saying you seem to continuously ignore the practicalities of the real world.
 
I simply despise people overflowing the market with shitty products.
 
Shitty by your definition
 
if you don't get what's wrong in it then you're apparently in the category of people I despise.
@phenomnomnominal yes, by my definition.
 
#define shitty functional
 
products that are inherently broken at launch or don't work whatsoever are shitty
 
12:04 PM
Yep. That's not most products.
 
If you don't agree with me then good luck buying i.e. a car.
@phenomnomnominal yep. After that we encounter the "most" category, which contains products that work more or less poorly, which is of course subjective.
in software development it's especially popular to ship crap because it usually doesn't mean human lives.
 
Making a new web-app? It might run a little slow on older devices, but you can mitigate that. It's not worth the time/effort required to fix that entirely, that's basic economics.
 
Altough Toyota managed to ship shitty software in cars that actually killed people...
 
You're solution, to change the underlying structure of the web, isn't practical.
 
@phenomnomnominal Yes, it's profitable to sell shitty products, I won't argue with that even for a second.
It's certainly more profitable than making and selling quality products.
Whether it's ethical is another question.
 
12:06 PM
We're not talking about writing Nuclear Powerplant control systems in JavaScript.
Capitalism isn't ethical.
 
or is it?
 
That's why our entire civilization is fucked.
 
@phenomnomnominal Right, because there's ASP for that.
 
@phenomnomnominal if that's your ultimate goal then I don't know what else I can tell you
 
My goal isn't for that to be true, it's simply inevitable.
 
12:08 PM
that's your opinion.
and basing on it you don't do anything to change it.
I bet if you were born 100+ years ago you'd say the same about slavery.
 
No I don't. I do my job to the best of my abilities, within the monetary and time constraints laid out to me by my employer, so I can live a reasonably comfortable life.
 
And so do millions of other people, so that must be justified, right?
 
@BartekBanachewicz That's about the most offensive thing anyone has ever said to me, and totally uncalled for.
 
Because most of the people simply don't care, not caring must be right.
 
You can care deeply and still not be able to change the fundamental flaws in a system.
 
12:10 PM
If you care, you push for changes.
 
@phenomnomnominal Time to block him yet?
 
If you just state that you care and then wait in apathy saying how we're all fucked then frankly, you don't care.
 
Okay, so I'm gone for a few minutes, and apparantly the conversation has shifted from VS being a shitty IDE into ethical software and business practices?
 
or maybe you care just a little, which doesn't really make the point invalid.
 
@BartekBanachewicz current rate we're going, we are fucked. I care very much. I care so much I probably won't have kids becuase that seems unethical to me.
I'd be kidding myself if I thought I could make a difference.
 
12:12 PM
See, and I instead spend hours talking to you about how shitty JS is because I actually believe it can be improved :)
 
If you're trying to equate the state of JavaScript with the state of the world, then you're more out of touch than I think you realise.
3
 
@phenomnomnominal Making a change is hard, but we all do it. Some more, some less.
@phenomnomnominal Why, now? JS is a part of web ecosystem. WWW is the huge part of the changes in the last few decades that changed the way we think about knowledge forever. Doesn't mean I'm equating that, of course.
 
Yes, but typically change happens through rational discussion and collaboration. Not one dude going "This is shit, do it my way."
 
Also it was you who brought up the "world is fucked" argument up, not me.
I actually just wanted to improve web development, not the whole world.
@phenomnomnominal Those "one dudes" typically go down in history (if they succeed, of course) ;)
 
@BartekBanachewicz yes, but everyone who knew them though they were assholes.
 
12:16 PM
@phenomnomnominal Maybe that's the price you pay for destabilizing people's views and angering them enough to push for change.
 
Wanting to make web development better is a noble goal, and one that I'm sure everyone in this room strives towards.
 
@phenomnomnominal I believe you've just said that you're content with the web as it is as long as you can make comfortable living, which would hint at exact opposite.
 
@BartekBanachewicz I never said I was content with the web as it is.
 
@phenomnomnominal I hope you're not :)
 
12:17 PM
> "I do my job to the best of my abilities"
 
that doesn't imply pushing for change.
 
Part of that means pushing what and how we build things on the web forward.
 
c'mon the internet explorer is awesome!!!
 
@phenomnomnominal and to do that, you have to realize what the problems are first, don't you?
sometimes they might not even be that apparent.
 
@BartekBanachewicz if you spend your whole time focussed on the problems, instead of working towards the solution, you'll never get anywhere.
 
12:20 PM
@phenomnomnominal I'll stop assuming you don't care about improvements if you stop assuming I'm not working towards solutions :)
I know I shouldn't be such an asshole about that, though :<
Can't help it, I'm sometimes too idealistic and don't like accepting other PoVs. Trying to change that, too.
 
Hi people. Does somebody here use the SE-Keyboard-Shortcuts extension ? It stopped working for me and I wondered if you had some info
 
That's reasonable. And I definitely don't disagree with you about most things you say. I just react to what I perceive as being a dick badly. We all have stuff to work on
Especially when it's 1.30am.
 
uh oh
it's 1pm here
 
Yeah, I'm not so good with the sleeping.
 
anyone attending hack.summit() here?
 
12:23 PM
Too busy working on things to improve the web :P
 
@AwalGarg I've heard about it
 
@BartekBanachewicz I've heard about it too! But are you attending it?
They say Jon Skeet is coming :p
 
@AwalGarg hadn't had time to look at it
 
Sarah Allen is coming OMG!!!!!!!!!!!
 
12:37 PM
hello guys
 
@king 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 need a help regarding javascript
here is my mark up <li class="list"><a href="" id="dynamictext">Left top corner of ad block looks sharp cornered as compa to the other corners.</a></li>
I need to do some javascript text manipulations which i can do by using a tag's id which is dynamictext but instead of that i want to do it through ul or li tag .can anyone help in this /
 
Why you want to do that by the ul or li tag if you can use the id?
 
@king what do you want to... do?
 
how about you make a fiddle?
 
12:46 PM
@king
@king jsfiddle.net/eycjx0ns -- there you go, I got you started
 
thanks @rzyns
 
@king np
@king if you can illustrate your problem more clearly in the fiddle, we can probably help
 
yep
added please check
I want to do text manupulations of the text inside anchor ta g
problem is i cant use the id for anchor tag because angchor tag itself is a dynamic entity her e what is can do isi can use li tag or ul tag for these below statements
var anchor = document.getElementById('dynamictext');
var listheight = document.getElementById("dynamictext").offsetHeight;
 
1:01 PM
@king you can use document.getElementsByTagName(), document.getElementsByClassName(), document.querySelector, or document.querySelectorAll()
 
yeah but how I'm gonna target a from li's tag because i need its offsetHeight etc
 
@king .childNodes()?
 
i tried not getting the values
 
those methods mentioned by @rzyns are Element.prototype functions, so you can call them from any Node
 
yep
 
1:09 PM
> SEND IT AVI VIDEO FILE, SO THAT i CAN PUT IT INTO A VIDEO FORMAT.
oh god
 
ok
listen to me now, everyone yeah, one developer, i would call my senior, thinks (i think he does) that dynamically loading a js file and running some code straight away is a good idea
but I am not able to digest this idea
Any Thoughts ? maybe with references ?
 
@CustomizedName If I understand you correctly, that's the same thing as a lot of stuff does, e.g. Google Analytics
 
hello, i have file server side which i want to download client side following a click on a button
is it possible to do it via jquery or js ?
 
how about a link
 
server doing download from client?
 
1:20 PM
no
client doing download from server
 
you just need a link to download, nothing more. From browser or jquery function (redirect).
what's your issue?
there is no secret.
 
i forgot to mention that i do not want to change page
 
xxx files are the best files
 
the page wont change if you "redirect" to a download link.
the browser knows.
 
@Mosho Are they porn files?
I bet they're porn files.
 
1:22 PM
create a dummy html with a real link to a file and click on it. It will open the save dialog and wont change.
 
can u show an example please ?
 
not sure how to do it right now.
<a href= "http://www.valid-link.com/file.zip">
can't be more simple
 
this.init = function(){
  this.el.onclick = this.handleClick;
};
this.handleClick = function(e){
  var el = e.target;
  this.doSomethingTo(el);
};
...
can someone give me the low down on how to pass 'this' as a parameter to the click handler?
 
var self = this;
change this to self
the this inside the funciont(e) must be self
self.doSomething
 
but this doesn't refer to the object in the first place?
 
1:26 PM
not in that case
 
it does, but inside the function, the "this" is another "this" from function
it's relative to function
done.
 
Yeah, so how can I pass the object into the click handler?
 
when it will be called it will be called as this.el.onclick()
so whatever this.el is will be the context when it's called
you need to do this:
this.el.onclick = this.handleClick.bind(this)
then the context will be right
 
this.handleClick.bind(this will bind it self
must be bind(self)
 
nope
 
1:28 PM
hmmm i need some test.
 
@Mosho Ah thanks :)
 
you're right.
 
Can that be done in timeouts too?
 
yes
 
var t = setTimeout(functionName.bind(this), 200);
saweet :)
 
1:30 PM
@Ismael i am getting this error The requested URL /puma/<a href= "coherence/parc/Gen_Parc_G07R03T00_20141104.csv"> was not found on this server.
 
can you confirm if it does exists? type the full url in the browser.
if it doesn't, it doesn't exists =P
 
it does exist
it does
in fact why is the url like this ? /puma/<a href= "coherence/parc/Gen_Parc_G07R03T00_20141104.csv">
when it is supposed to be like this /puma/coherence/parc/Gen_Parc_G07R03T00_20141104.csv
 
because it's wrong, need to fix it
whoever did it
 
G'day. With Angular, is it typical to have multiple controllers per view (is it even allowable)?
 
var path = "Gen_Parc_"+str.substring(0, str.length - 8) +"_"+str.slice(-8)+".csv";
var href = '<a href= "coherence/parc/'+path+'">';
window.location.href = href;
this is how i did it
 
1:35 PM
why don't you use code blocks for code
 
@Dave it is. otherwise it will be spaguetti.
@Joseph var href = '<a href= "coherence/parc/'+path+'">'; is wrong
right: var href = 'coherence/parc/'+path;
the URL must be a path and not and html tag.
window.location = 'expect/a/path';
window.location = '<not>/a/<tag>';
 
Yes but this will open my file in the browser
i am looking to save my file not open it in the browser
@Ismael :)
is it possible ?
 
i cannot understand what do you want? how can download be done without the browser?
you can open/save as/cancel. Nothing more.
 
yes that's what i want to do exactly , but instead it is opening the file in the browser page :(
 
hmm some kind preview?
it is possible
 
1:51 PM
@Joseph You want the Content-Disposition HTTP header. Won't work without server involvement.
 
@RoelvanUden can it be done with javascript ?
 
Thank you @Ismael
 
right click then save target as
 
I have this
i want a save as box instead
 
ahhhhhhhhhhhh
it is php?
 
1:53 PM
no, i know how to do it with php ,
i was just wondering if its possible with js
 
it is not
 
ajax
 
but can be done on apache.
 
wait what
guys
you can change the header when sending via file api, no?
 
he wants to download the file instead viewing in the browser.
 
1:54 PM
@Joseph Yes, it can be done with JS... if that JS is running on the server. o_o
 
content type does not matter.
 
uh can't you XHR the file and resend it with this header
 
It's just the content-disposition header you want.. thus, server.
 
it just tell if the file is image, mpg, etc.
 
yeah my bad
still.
 
1:55 PM
@RoelvanUden is right.
 
okay then. i will do a server call
 
@RoelvanUden @Ismael @Joseph or just resend with a different header
7
Q: Request a file with a custom header

KrisI have an unusual requirement. Essentially I need a way so that, when the user clicks on a link or button, they will receive a PDF. The tricky part here is that the server won't process the request at all unless a custom header is sent with it (otherwise it deems the person logged out and sends t...

 
Let's download a huge file in XHR to JS (ouch), use browser-specific conversions (ouch), hope the browser supports it (perhaps sniff it and update this JS forever), and then re-serve the file somehow hoping the browser will understand? I don't think it's a good idea at all.
 
everything's better than touching PHP vOv
 
2:01 PM
zip then download. this will finish your problem
 
^ worse than two idiots one keyboard
 
hello guys
 
2:16 PM
Is there a way to access the data attribute of selected <options>? jsbin.com/koceqofume/1/edit?html,js,console,output
 
I'm getting an error for my code in mozilla but not in chrome.In chrome its working fine
here is my code my trying to keep the text always at vertically center
getting this error in moz
TypeError: paratext is undefined breeders:165
"paratext" undefined
anyone there?
need this help
 
I'm trying to find duplicates for these 3 columns:
damm, no ctrl-v
select *
from [WCS].[dbo].[PLCMemory]
where EXISTS (select
null
from [WCS].[dbo].[PLCMemory]
group by [Address],[Value],[Language]
having count(*) > 1)
doesn't return the duplicates, what is wrong?
 
anyone there/
?
 
2:32 PM
Wrong chat?
 
My internet connection really sucks!
 
@king don't use innerText
that is causing the problem
look up the compatibility charts for it, and look up the common workarounds (or whether or not you even need to support the older browsers)
var paratext = targetpara.firstChild.innerText;
focus on this line
good luck!
 
@rlemon thanks but wat shud i use instead?
 
ask google (I'm trying this new thing where I set people on the right path instead of giving them the answer. I feel like you'll learn more this way)
 
2:40 PM
Hello, I'm Google, you asked for me ?
use .textContent instead Better ask the real Google
 
and then jAndy comes in and ruins it
:(
 
Hello Im Bing, its better to use Google
 
google-fu isn't something you're born with. you have to train long and hard. many keystrokes, much clicking, so bookmarked.
 
Google in fact took over a lot of brain capacity and thinking...
some day...
we WILL have the Mother Brain
remember that one ? Metroid... ?!
 
no comments?
 
2:44 PM
 
how sad is it that I didn't realize Samus was a girl until like 3 years ago
 
This is what Google will look like, SOON
 
@rlemon fairly worrying!
 
as well, you should !
 
I know right! look at that booty! clearly a womans figure
 
2:45 PM
Geometry problem (this is not homework, just a thing I was curious about): I have an isosceles triangle with know angles (smallest is 72°), and it's middle vertex is the center of a circle with the same radius as the base of the triangle (L). How do I find out the area of the circle that's beneath the base (A)?
 
<3 dat 8bit ass
 
of course, based on L
 
I dont like problems
 
Thank you. Trying to write better answers.
 
I don't even know where to start
 
C D
2:57 PM
can't get the data from a json feed, can anyone throw a hint please?
$.getJSON("http://www.football-data.org/soccerseasons/358/teams?callback=?", function(data){
console.log(data);
});
 

« first day (1503 days earlier)      last day (3446 days later) »