« first day (1567 days earlier)      last day (3367 days later) » 

12:04 AM
!!> var hello = 'hello'; hello.blah = 'blah'; console.log(hello, hello.blah)
 
@phenomnomnominal "undefined" Logged: "hello","undefined"
 
@rlemon
 
@SecondRikudo rlemon is afk: gym
 
12:28 AM
any one want to offer their take on what problem/design angular.js solves
 
gives backend devs a warm fuzzy feeling when working on the frontend.
 
1:16 AM
@SterlingArcher feels
 
 
2 hours later…
3:24 AM
> Do not assume that your source code is secure
 
@CSᵠ Why not? It compiles so it must be right
 
yup, that's `nuff
 
 
1 hour later…
4:51 AM
hi
 
Hello.
 
I was having a problem with express socket.io yestarday ( i don'tt have the code with me now),
This is what I was doing,..
var express = require('express'),
      app = express(),
     server = require('http').createServer(app),
    io = require('socket-io')(server);

app.set('port', 8000)
app.get('/', function(req, res) { res.render('index') });
io.on('connection', function (socket) {
  socket.emit('news', { hello: 'world' });
});
//and other stufff like setting the view engine


//and in views/index.jade I had

doctype html
 html
  head
  body
    script(type="text/javascript", src="/socket.io/socket.io.js")
    |<script type="text/javascript">
I don't remember the exact error but It was showing some error in line console.log(data), undefined method. what am I doing wrong?
 
My hobby: Pretending to miss the sarcasm when people show off their lack of interest in football by talking about 'sportsball' and acting excited to find someone else who's interested, then acting confused when they try to clarify.
3
 
really!!
 
5:41 AM
Super Bowl of Snacks (tm)
 
@Zirak I now use jsh full time to test snippets =)
 
5:58 AM
Anyone integrated facebook stuff in your website ? like post something on user wall
 
6:16 AM
@BenjaminGruenbaum It's possible to get the location path name for $rootScope.path without inject the $rootScope to the controller ?
 
@underscore BenjaminGruenbaum is afk: gnight :D
 
6:31 AM
Hi lodash
 
user4202350
Hey Java-Script
 
Any good Javascript/jquery template plugin?
 
@Mr_Green Mustache?
 
@SomeKittens ok will check
@jdphenix thanks for that link
 
7:15 AM
@underscore sure
 
Hey all... anyone has worked with backbones.js?? i am facing a small issue
i wanna pass an array from one router to another like this : this.navigate('#newPage/' + myObject, {trigger: true, replace: true});
i can pass any primitive type like string int but i can't find any way to pas an array like this
 
Any thoughts on React Native ?
by the looks of it ?
 
7:38 AM
0
Q: Backbone.js- pass array from router to router

SweetWisher ヅI am facing a small issue in backbone.js I need to pass an array from one router to another like this : this.navigate('#newPage/' + myObject, {trigger: true, replace: true}); where myObject stands for an array of my custom object I can pass any primitive type like string, int etc. But ...

 
7:57 AM
Sorry ahead of time if this is a bit long...
I have a dynamically generated `<iframe>` with attribute `srcdoc="<html><body><form action='/messages.xhtml' method='post'><input name='u' value='kaloncpu57'><input name='msg' value='" + message() + "'><input type='submit' name='submit' id='submit'></form><script>window.onload = function () {document.getElementById('submit').click();};</script></body></html>"`
Why would Firefox not run `document.getElementById('submit').click();` when it is generated, but if I go into the JS console I can `.click()` it just fine? Chrome does everything when the `<iframe>` is generated...
Oh. I didn't realize that it shortened messages automatically. :D
 
8:22 AM
got a jsfiddle?
 
8:43 AM
Hmm, cool. Most of the functionality you get on grooveshark.com can be performed through a javascript object, meaning in theory you could search for songs, add it to playlist and play them simply by running a snippet in your console
 
have grooveshark not been shut down yet?
 
apparently not
I don't know what the standing is though
 
fair enough
 
A lot of companies don't like grooveshark, that's for sure
 
Anyone aware of arrow ?
like gif arrow
moving towards a button
 
8:49 AM
Might be easier to use css animation you know
Would be more flexible too
 
ive no idea what you mean
 
@Neil yeah that's what i am trying to find
but i am not sure what people call it
 
@CustomizedName Start with an arrow image, put it where you want it to be, then make its start state left: -200px and opacity: 0, and make it move to state left: 0px and opacity: 100
 
use a time interval
 
9:14 AM
Hello
 
@LambodarSwain 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.
 
ok
thanks for the info
 
user4202350
@All_JavaScript_Users_except_uni Good Morning! Have a nice Day!
 
Hi all
does anyone know how i can refresh an aspx page from clicking links on the master page?
similar to this
0
Q: Reload A Page Without Reloading The Masterpage

Or BetzalelI have an asp.net website with a masterpage, when I press ,lets say login, it takes me to the login form using Response.Redirect("Login.aspx"); Now, Is there any way I can update the contentplaceholder without reloading the masterpage? Its actually for my music to keep running in the backgrou...

 
9:50 AM
I need to add lastname using prototype (broken).

person.prototype.lastname = "";
mario.lastname = bros;

document.getElementById('mLastName').innerHTML = mario.lastname;
 
where is bros defined?
 
lastname not defined in persons class...@UlisesContreras
 
@kathir @DrogoNevets Say undefined.

function person(id, name, lastname, old, country) {
this.id = id;
this.name = name;
this.lastname = lastname;
this.old = old;
this.country = country;
}
 
Good day
 
10:03 AM
But I'm adding with prototype a class to person (person.prototype.lastname) and person.lasrname = bross.
 
1
Q: Regular expression for matching exact word affect the special character matching

Shital KadamI want to highlight the words selected by user. I have written the code as var name = "and"; var text = "viverra*.and standard'android viverra'.Vivamus (sit amet felis) scelerisque) ullamcorper (erat) eu mat)tis lorem."; name = name.replace(new RegExp(/\[(.*?')\]/g), ''); var escaped= name.repl...

please see my question on above link. please help me.
 
@UlisesContreras trying to get you to think about why its undefined
 
@DrogoNevets undefined because vn't value.
 
I can't seem to set a radio button value using code.
$(document).ready(function () {

if(localStorage.getItem("back")=="true"){

document.getElementById("rbOther").checked = true;


}

});
that isn't working. And back is set to true.
 
@UlisesContreras so you've tried to do mario.lastname = bros yes?
 
10:09 AM
The radio button code is as follows :
<ul id="rbGroup_sw" data-role="listview" data-inset="true" data-theme="c" data-divider-theme="a">
<fieldset data-role="controlgroup">

<input type="radio" name="langs" data-theme="a" id="rbExhibitionSite" value="choice-1" checked="true"/>
<label for="rbExhibitionSite">Exhibition Site</label>

<input type="radio" name="langs" data-theme="a" id="rbCustomerSite" value="choice-2" unchecked="true"/>
<label for="rbCustomerSite">Customer Site/Premises</label>

<input type="radio" name="langs" data-theme="a" id="rbAgilityOffice" value="choice-3" unchecked="true"/>
 
@DrogoNevets Yes, using prototype. :)
 
@UlisesContreras so what is bros
 
@DrogoNevets lastname (adding using prototype) :)
 
hi @UlisesContreras bros variable not defined error
 
@UlisesContreras is it an integer? an object? a date? a string?
 
10:10 AM
@kathir I know, I need to add lastname with value bros using "prorotype".
@DrogoNevets string :)
 
@UlisesContreras is it? how do we define a string?
(you have the prototype bit right)
 
@DrogoNevets var lastname = "bros";
 
so whats different?
 
What with prototype I can to add this lastname with value bros.
 
FFS, look at your code, you'll kick yourself
you are missing 2 symbols
 
10:14 AM
Two symbols, hmm, I go to see, one moment, please.
OMG!!!! mario.lastname = "bros";
hahaha..
This is stupid!
God!
 
yes very!
:P
 
Thanks, @DemCodeLines I need more concentration.
 
its always the simple things
 
@UlisesContreras super man
 
10:17 AM
@doodla whats up?
 
hello guys
I want to highlight the words selected by user.

I have written the code as
var name = "and";
var text = "viverra*.and standard'android viverra'.Vivamus (sit amet felis) scelerisque) ullamcorper (erat) eu mat)tis lorem.";
name = name.replace(new RegExp(/\[(.*?')\]/g), '');
var escaped= name.replace(/([.*+?^=!:${}()|\[\]\/\\])/g, "\\$&")
var regexp = new RegExp("\\b(" + escaped + ")\\b", "g");
console.log(text.replace(regexp, "_$&_"));
but it does not replaces the special characters
 
10:30 AM
can any one knows?
 
hi any one know about my issue?
 
@FlorianMargaine TGIF
 
exactly
 
On Polish JS FB group someone posted that he wanted to develop with JS for MCUs
shitstorm ensued
 
10:35 AM
MCUs?
 
@FlorianMargaine Micro-Controller Unit(s)
 
so... things like arduino?
 
yea can't see that going down well
 
@FlorianMargaine yes... "things" like arduino
 
is it even possible?!
 
10:36 AM
@DrogoNevets There's Cylon.js
 
@DrogoNevets there are plenty of nodejs libs to do it
 
you wouldnt get node running on a duino though
 
@FlorianMargaine and no single one to do it well
@DrogoNevets that's because it doesn't have a gigabyte of RAM
 
dunno, didn't try it
@DrogoNevets ... you do
people run node on raspberry
 
Jo people \o/
 
10:38 AM
@FlorianMargaine rPis are very different to arduinos though
rPis are more mini sized linux computers, where as arduinos are far more basic
 
@FlorianMargaine raspberry and arduino are totally different things
 
oh, my bad
 
Pi has 256/512MB of RAM. Arduino chips have 2-8 kilobytes
I have a SoC that I want to program, but I wouldn't fit JS on it either, it has 192kB
which is more than enough for a very complex application written using a technology that actually makes reasonable use of resources
or maybe possibly a JS app that's able to blink a led
 
@BartekBanachewicz You mean PHP right? :)
 
@PeeHaa lol
 
10:41 AM
;-)
 
100 more rep to 15k
time to answer in
 
theres a project for someone!
(yes i know its fake)
 
hi guys i have some content that needs to load dynamically it works on one page for a single array item
  $('#coin1' + i + 1).text = result_array[1];
 
yay it works, job done!
THEY BUILT A RAIL GUN!!!!!!!!!!!!!!!
http://www.bbc.co.uk/news/technology-31041783
 
$('#msg_alerts tr').last().after('<tr id="' + result_array[0] + '"><td>' + result_array[0] + '</td><td>' + result_array[3] + '</td><td>' + result_array[2] + '</td><td style="color: red;">' + result_array[1] + '</td><td><img src="images/icon_mail-ur.png" title="Currently Unread" style="vertical-align: middle;"/></td><td><input type="checkbox" /></td></tr>');
 
10:50 AM
uugggggh
 
doesnt work for multiple array items
 
my eyes!
 
i put it here first guys sorry
 
@FlorianMargaine awwwwww
 
10:51 AM
Have any of your signed an Apache Contributor Agreement?
 
@SecondRikudo adding a static method to be able to inject dependencies is... awkward
 
I have a couple of questions and the Apache email auto-responder sounds like I shouldn't expect an answer in this century
 
so... I made this. Feedback? (docs, usage, etc. I know you guys don't know shit about code.)
5
 
You and your lisp :P
 
it's amazing <3
 
10:55 AM
@FlorianMargaine My reasoning being that you want your dependencies as close as possible to the class/object
 
@SecondRikudo your dependencies are specified in the constructor, what else do you need?
 
@FlorianMargaine Not their types
 
of course, it's duck typing
 
@FlorianMargaine And a dependency injection container needs the types
So since JS doesn't have types in arguments, and has no annotations, a conventional static method is the next best thing
 
@FlorianMargaine I might actually give it a try sometimes when I am really bored
 
10:56 AM
      var result_row_array = [];
      result_row_array = real_data.split("^");

      for (i = 0; i < result_row_array.length; i++) {
      	var current_row = [];
      	current_row = result_row_array[i];
      	var result_array = [];
      	result_array = current_row.split("¬");

      	if (result_array[0].length <= 200 && result_array[0].length > 0) {
      		$('#msg_nomsg').css('display', 'none');
      		$('#msg_alerts tr').last().after('<tr id="' + result_array[0] + '"><td>' + result_array[0] + '</td><td>' + result_array[3] + '</td><td>' + result_array[2] + '</td><td style="color: red
doesnt dynmamically update
 
It's preferable to configuring it all on the injector, because then the dependency types are away from the class/object in question.
 
@SecondRikudo ... how does angular do it?
@PeeHaa :P
 
Why do you initialize result_row_array with an empty array just to overwrite it in the nxt line?
 
however this one does
 
@FlorianMargaine With an array of strings I think
 
10:57 AM
Don't do that. use var result_row_array = real_data... instead
 
@SecondRikudo for the controllers yes. For the services?
 
function displayCoin(x) {
	x.success(function(real_data) {

		var result_row_array = [];
		result_row_array = real_data.split("^");

		for (i = 0; i < result_row_array.length; i++) {

			var current_row = [];
			current_row = result_row_array[i];
			var result_array = [];
			result_array = current_row.split("¬");

			$('#coin1' + i + 1).text = result_array[1];


		}

	});
};
 
also, splitting strings? why not use JSON?
 
@PeeHaa you mean lisp or lxc-wrapper?
 
@FlorianMargaine Not sure, haven't used Angular for that long.
 
10:58 AM
The first. Then I might have a fucking clue what lxc is / does / means :P
 
@PeeHaa oh. No.
 
CTO does not like JSON trying to minimize usage of it :/
8
 
lxc is completely unrelated to lisp
it's what docker is based on
 
Don
guys please help me on my thread "How to enable video seekable in HTML5?" stackoverflow.com/questions/28233595/…
 
except I don't like what docker does, so I use lxc directly
 
10:58 AM
@Don 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.
 
but its API is awkward
hence a wrapper
 
@FlorianMargaine Ooooooh that other thing on my list :)
 
@Corbo152 Your CTO sounds ancient. Is the CTO a dinosaur perhaps?
 
@RoelvanUden maybe it's dippy the diplodocus and he's jus tmiffed he's being disassembled
 
@RoelvanUden old skool guy... asp web forms and even the DB still has legacy code :/
 
11:01 AM
@Corbo152 see that's the problem you should fix first
 
why people dont just upgrade to latest web technologies i dont know
the drive forware is to go completely client side lol
 
@Corbo152 because the vast majority of latest web technologies is complete shit
 
forward*
 
@Corbo152 and that doesn't mean it's a good direction
 
New != better. But anything > WebForms.
 
11:03 AM
Accepting every new solution as a silver-bullet-ish breaktrough is as bad as using webforms
 
@BartekBanachewicz agreed... however its an ongoing argument client side v server side... pros and cons to both lol
@BartekBanachewicz completely agree that MVC is the way to go in asp tho... and any new projects i start will be MVC
 
OMG found a page for that MDN is #1
!!google addEventListener
 
so anyways before a mass debate is started back to the matter at hand... im stuck with what i have in this project... can anyone help me fix this issue with the JS
 
@FlorianMargaine ip regex is too broad.
*default
 
11:09 AM
officially never have use dreamwever :D (just been told i have to remove it from my machine)
 
@CSᵠ I actually plan on removing that
 
why?
 
!!MDN addEventListener
 
@CSᵠ it's only useful if porting this to windows, for example
which is not really useful
 
11:12 AM
lol, yeah
 
why can't I do $("input").dblclick() ? I have a datalist, but I wan the dropdown on a single click not double click
 
holy hell the shitstorm
 
Because dblclick doesn't exist? >_<
 
> but JS is perfectly fine for prototyping
> but weak typing
someone hold me
 
People that don't get JS always hate it. Especially good static-typed OOP programmers that haven't invested time in understanding JS.
 
11:15 AM
no I can do .ondblclick = function() { blabl }
 
Guys I want the regex to match string with contain either of the following: x, X, y, Y
 
@deostroll /[xy]/i
 
sorry not match...test
 
@RoelvanUden I disagree.
 
@BartekBanachewicz How come?
 
11:16 AM
I know quite a number of people that don't get JS but are either neutral or love it.
 
so .keyup and .keydown also doesn't exists ?
 
@BartekBanachewicz Really? That surprising. I only see hate for it in .NET world.
Perhaps they already know other dynamic typed languages?
 
@PeeHaa yep. thanks. :)
 
@RoelvanUden remove the blinds then.
 
np
 
11:18 AM
@RoelvanUden No. I can assure you that people who sit to JS as a first language might well like it a lot. And still don't get it in the slightest.
To really deeply hate something you have to understand it IMHO.
 
Hello everybody
 
haiiii
 
Hello @dystroy
 
@BartekBanachewicz Not sure what programming environment come from, but I just have the experience of .NET shops and an education that focused solely on static languages. It has been my experience that it is really rare for someone to like JS, or embrace loose typing. Might be a dutch thing. We tend to hate shit. :/
 
11:20 AM
hey @dystroy
 
hey @PeeHaa
 
@BadgerCat o/
 
Enough social interaction for a day, bye all.
 
@BadgerCat :(
 
Have a good one @BadgerCat
 
11:22 AM
@RoelvanUden "loose typing" whatever you mean by that is typically hated by every one that knows anything about typing in general, because it's flaw, nothing more. Also most of the people I know don't like JS for JS, they like it for the ecosystem.
I'd argue that if you like JS for the language your views are either very limited or you're very weird.
 
I guess I'm very weird?
 
I think JS is an elegant little language. So that makes me weird then?
 
yeap :)
 
@darkyen00 ping ping
 
I just realized some of my habits are obsolete. @FlorianMargaine wanted the lists of top 10 youtube vids in the miaou db. As no index can help there I thought it would too slow and lose time looking for an idea. Then I tested the regex match on a full scan on a room. Then on the whole DB (810k texts). Results come in 2s. PG is impressive...
 
11:24 AM
help me please
 
(weird here too)
 
@AwalGarg Did you just got revived ?
 
@RoelvanUden dunno. With @Florian it's certainly that, but I don't know what other languages you're familiar with.
 
@AwalGarg where ?
 
@darkyen00 dude, miaou?
 
11:25 AM
dude office
got too busy.
 
@darkyen00 :( when can I find you on miaou?
@argentum47 home
bad time
 
how bad
 
@BartekBanachewicz :P
 
very bad
42 bad
 
@FlorianMargaine no seriously though ES is soooo meeeh compared to the alternatives come on
 
11:26 AM
@dystroy I like your old habits though, being performant is very often an after thought...
 
if you stop caring about the ecosystem for a moment all of the research langs are just amazingly better
 
@BartekBanachewicz come on, especially es6 is very nice
 
@FlorianMargaine it's not like we're not waiting for ES7, no?
and it's not like ES7 is already years behind :P
 
Uuuh I'm not
 
@BartekBanachewicz So knowing other languages should make me take less of a liking towards JS as a language? I know quite a few languages. C#/JS as main; other knowledge includes, but is not limited to, Java, PHP, Python, Lua, VB, and tons of shit I forget to list as usual.
I don't think you can judge whether I should dislike JS :P
 
11:28 AM
Afk shower
 
@RoelvanUden Do you know any non-mainstream languages?
The ones that weren't created for the industry needs, but in order to create a good language?
 
@BartekBanachewicz Define "non-mainstream"
 
@RoelvanUden not being primarily influenced by popular industry usage and needs
 
rumour has it es6/7 are coming with template strings
 
You want to know about functional languages? Then sure, F#, Lisp, Prolog
I don't like them at all.
 
11:29 AM
@RoelvanUden funny.
 
that should be cool
 
discussion point, is it ok to shout at people if they are incompetent and unable to do their job/folow simple instructions?
 
Ah food time. :-D
 
@argentum47 how you doing these days?
 
that should be cool
 
11:30 AM
@RoelvanUden you don't like lisp? You haven't seen the light...
 
@DrogoNevets does the shouting solve the problem ? Or just create other ones ?
 
@BartekBanachewicz in 2 hours I'll show you another example of macros that I had recently
 
@dystroy it makes me feel better - we dont know how to solve the problem, he's one of those annoying types that does just enough not to be able to fire him
 
@FlorianMargaine ah cool
 
@SomeGuy IIRC, some official guy tweeted with a justification saying that those sites hold some ISIS content, which is harmful for the country. But I haven't been able to follow the thing :(
 
user4202350
11:33 AM
Hello JavaScript
 
user4202350
and How are you?
 
god not again
 
@AwalGarg I am doing not good, I am studying E and A of MEAN , and trying to make a chat application p2p.
like whatsapp
:P
 
@argentum47 as in, academically?
 
I need a javascript calendar plugin which has IE8+ compatibility. a better one. any links?
Note: not jquery
 
11:44 AM
!!tell Mr_Green google javascript calendar plugin -jquery
 
umm, no
well, googling that would give the result. ain't sure why caprica gave different results :/
 
@AwalGarg hey
 
@Zirak does caprica not respect the -keyword google search rule?
@Mr_Green o/
 
user4202350
difference b/w styleId and ID ?
 
11:49 AM
@AwalGarg academically , well yes, if it works then my friend intentds to do something with it
 
"works"?
 
Anyone have much experience with KineticJS? Am I better off creating a grid using rect or line? Bearing in mind the grid co-ords need to be mapped to an object.
 
12:07 PM
hello everyone
 
HAHA its confirmed, 50 motorbikes will be escorting me from my wedding
 
can anyone point me to a tutorial where i can see how to extract a BLOB file?
 
from where?
what for?
 
i manage to post the file, and i can see it in the server...but now, when the user opens a view i want to extract the file and show the file (.png)
 
@Japa why are you transporting an image inside a blob?
 
12:11 PM
@DrogoNevets hah, that's cool
 
@DrogoNevets i thought it was the proper way to save it :( ... the idea is(and this part is working) the user has a imput type file, choses a image from the desktop and it appears in a div below...then he saves...but i want to show the image when the users returns to the view...
the remaining imputs in the view are just text...i´m getting the info from the server with the $.ajax function ...
 
I hope this answer helps someone facing the same problem as I did.
0
A: Get nearest location from a set of predefined locations

Rahul DesaiI was able to solve this in following way: Get lat, long co-ordinates of the input zipcode from this URL: http://maps.googleapis.com/maps/api/geocode/json?address=zipcode (add zipcode) Take average of the lats and longs of northeast and southwest returned in the response of this URL. Consider t...

 
Pfff
@dystroy - Dont be so judgemental. if you don't know, or don't want to answer, choose to remain silent — jane juan 8 mins ago
 
@AwalGarg works meaning ,if I can implement that thing, I am late in replying because I am at office
 
@DrogoNevets do you know a better way?
could you explain to me?
 
12:21 PM
why could my head teacher never be this cool?!
 
@DrogoNevets soo, you comment on my question..do you any any suggestion that could help me?
 
@AwalGarg Yeah, I've heard things like that too
 
-1 for not actually committing to the egg and using the <marquee> tag.
 
@KendallFrey google.nl/…
 
old :P
 
true :)
 
They still have "do a barrel roll"
 
12:49 PM
And "zerg rush"
 
and "kerning" and "keming"
and "askew"
 
I don't think I see the kerning
 
"tilt" works too :)
 
user4202350
javascript
 
@PeeHaa look at the search results
 
12:52 PM
ow lol
 
user4202350
JavaScript is is java.
 
This sh*t is painful...
-2
Q: remove array value after index

ramHow to delete values from array after index ? var array = [5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60]; I tried like using slice(): var new_array = fruits.slice(2); // console.log(new_array ) prints [15, 20, 25, 30, 35, 40, 45, 50, 55, 60] But i want the output to delete all values ...

 
@ShaU I think you meant "JavaScript is a FactoryFactoryJava" :P
 
@BartekBanachewicz so there we go. The first one I wanted to show you was this one
because it's an example of an hygienic macro
 
show usage
 
12:55 PM
as you can see the (let ((stream (gensym))) is not backquoted, so it's run at compile time
and the gensym function returns an unique symbol
which means that the stream will actually contain a unique symbol, so the macro is completely hygienic (you don't risk using a variable with the same name as the one generated by the macro)
also, why I originally made this macro: the original API requires this: (run command '(arg1 arg2 arg3))
which is ugly
so the macro allows me to just write (run command arg1 arg2 arg3)
it allows me to: define a function, and add the function to a global hash table, by using a string of the function name as key
 

« first day (1567 days earlier)      last day (3367 days later) »