« first day (1034 days earlier)      last day (3930 days later) » 

user1125394
5:00 PM
!!convert 68612.70 EUR AUD
 
@cx 47392.2772EUR
@cx 99334.8042AUD
 
HEY @OctavianDamiean
HEY
HEY @OctavianDamiean. GUESS WHAT?
DID YOU GUESS YET?
I WIN
 
@MLS 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.
 
MLS
ok
 
user1125394
don't feel distracted by her
 
5:10 PM
Well, feel a little distracted by her
 
user1125394
she's just a blonde
 
@Darkyen sorry am currently in Germany wi h only my phone. Won't be able to help before coming back on Tuesday night (GMT +1)
 
Awww, come on
Does anybody know what happened to @KirstyHarris? Did we scare her away?
 
@Esailija make a pull request ;)
 
IT is a robot don't feel distracted at all
 
5:12 PM
@Zirak hahahahahaha
Arnold voice is gangster
 
@Batman 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.
 
Any know why this wouldn't work?

//Remove New option
$("select[id$='ct100_DropDownChoice']").removeChild($("option[value='New']"));
 
user1596138
@Zirak I've never wanted you so badly
 
And that's saying something
@Batman jQuery doesn't have a removeChild function?
 
oh ic
is there an alternative?
 
m59
5:22 PM
It's just .remove
 
$("select[id$='ct100_DropDownChoice']").find("option[value='New']").remove();
 
ah kk thank you!
 
Or even shorter: $("select[id$='ct100_DropDownChoice'] option[value='New']").remove();
 
I guess I don't really have to use the parent here right, couldn't I just do: option[value='New']").remove();
 
If that works, great.
 
5:23 PM
kk ill give that shot thanks.
works, thanks!
 
user1125394
god fuck mosquitos
 
@cx I don't think he should
 
Does anyone know of a decent set of styles/templates I can use for a CMS?
like any of the CSS frameworks but domain specific
 
rocketthemes.com
 
5:30 PM
@Batman This webpage is not available
 
That's a bit too far in the domain-specific for my needs. I want something closer to 'Here's some CSS files and instructions for writing your HTML'
ie, 'Here's a table good for displaying this type of data, here's a blah for blah, etc...'
I often find I ask for things that don't exist.
 
Hey ppl
whats up
 
My pizza erection
 
welp
 
5:33 PM
for whatever reason, bootstrap btn-group keeps messing up for me
 
/installed konami code onto a CMS.
@Crowz use the Chrome element style inspector, Luke.
 
/* ==UserStyle==
 * @name		Chat
 * @description		Extend Chat Style
 * @version		1.0
 * @match		chat.stackoverflow.com*
 * ==/UserStyle==
 */

.message a{
    color:#00f;
}
I wish
 
@Incognito I tried, but for whatever reason, the buttons just aren't connecting
 
wat?
 
@Shmiddty ... you wish what?
 
5:39 PM
@Incognito okay, so they're in a <ul class="inline">, and the two buttons just don't quite come together into one single button
 
@Crowz use the inspector, see what's over-writing it.
 
I wish that UserStyle was a standard and worked natively in chrome
 
I have no idea what's in your class.
 
I don't want to download an extension.
 
Ah
FWIW, Stylish is pretty good. I use it for a lot of stuff.
 
5:41 PM
@Shmiddty I downloaded an extension to make the entire web green on black.
 
@RyanKinal I can add styles to a userscript for the time being
 
I believe the phrase I used was "The web is a mess, and I just need to rule it"
 
The slurry of garish design is a non-stop assault on my eyes. I don't give a **** about your design, I just want to see the information in a consistent way.
 
@Incognito this can be solved by a firewall
just block all CSS
 
Then the structure breaks
CSS is colours and dimensions
 
5:42 PM
so you're writing a userscript for each site you visit?
 
Yeah. Because everybody on the web totally writes their HTML in a way that makes sense without CSS.
 
@JanDvorak It's one plugin for all sites.
And it's never been smoother
 
I guess it only affects color and background?
 
Every page looks the same, I don't have to re-learn what you mean with all these boxes
Basically.
 
just redirect all CSS requests to a custom handler that spits out the same CSS
 
5:43 PM
I miss gopher://
 
link pls
@Shmiddty 'just'
 
link please
 
@JanDvorak Looks like it was removed from chrome store chrome.google.com/webstore/detail/…
 
5:45 PM
can you make it a userscript?
screenshot pls
 
@JanDvorak I've been debating doing that.
 
@RyanKinal ... thanks
 
No problem
 
@JanDvorak I uninstalled my screenshot because I kept hitting the key randomly.
I'll fix it some day.
If I made it a user-script I'd also like a delete-element-on-click option.
 
@Incognito how do you uninstall a key?
 
5:47 PM
hi hi
 
@JanDvorak The software is bound to the key by your window manager
Half the sites I hit I feel the need to delete entire sections of the page. Full of spamvertisements or noise.
 
my window manager is not exactly configurable
 
@JanDvorak I don't use windows or mac.
 
I do
 
You can do powerful things with powerful systems.
I use windows/mac only when I absolutely need to.
I like Arch Linux, and FreeBSD as an OS of choice.
 
5:49 PM
It's time for me to rethink installing a linux
what about SUSE?
 
Since finding this chat room - my JS skills have gone from 'barely making it by' to 'I can do that, no problem' - love you bitches
 
SUSE is fine, but you should really learn a lot about linux internals and how popular software on them works.
 
@jbolanos we love U2
 
sorry, not linux internals, but rather linux usage on a command line level.
Right now I'm using xmonad.org as my window manager, but like Arch and FreeBSD they're not things I'd advise to someone with little experience.
 
@Incognito I was wondering that I might like Unity 3, but Suse doesn't come with Unity
 
5:50 PM
@JanDvorak I answered the closure question in an interview yesterday and then made them feel silly for asking stupid questions :)
 
Unity/Gnome/KDE aren't really my choice of WM, to me less is more.
 
hey guys - i set the innerHTML contents of an element - is there a way to get that data i entered in another script on the same page?
 
@Incognito I'd like a touch-friendly front end
 
xmonad is 1000 lines of code, and it tiles windows. You don't even need a mouse to use it, but you'll have a bad time if you're new to that.
It all depends on what you're doing with the machine I guess.
 
@KevinMurphy window.somedata = 'something' you can then access that anywhere on the page
 
5:52 PM
sweet thanks
 
I have a convertible. I never really convert, but I do touch a lot
(though the Synaptics touchpad is great, too)
 
@KevinMurphy You could also use functions and just return whatever that value is as a result. developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/…
 
has anyone plowed into jQuery 2 yet?
 
@jbolanos It's basically the same
 
@jbolanos its the same, just doesn't support IE. as far as i know
 
5:53 PM
basically, I've maxed my touchpad inertia, and I love that
 
I tend to stay away from mobile, but I get my Firefox OS developer phone next month and I'm really giddy about it.
 
@Incognito nice. I was thinking of android as a safe bet for something that will stay
 
Stay?
 
I don't want something that will lose support before the phone dies
 
@Connor paste.ubuntu.com/5989918 when i convert var contents and contents to window.contents, everything breaks :/
 
5:56 PM
@Incognito I've tried xmonad... I preferred stumpwm. But awesome wm is definitely my favorite.
 
@KevinMurphy do var contents = window.contents = 'yourContent'; then
 
I've tried xmonad, too. But failed configuring it. It's much better with awesome and Lua
Everyone can write Lua, you just don't know it yet
 
@copy nah configuring was ok once I went on #xmonad, but it didn't fit my taste
 
user1125394
xmonad -> haskell:)
 
@KevinMurphy and you should change this
var contents = $('.target').val();
var contents = contents.replace(/n/g , " ");
you shouldn't have the var on line 2
 
5:58 PM
And I remember there were things I couldn't do, although I don't remember what
 
@FlorianMargaine I was going to install wmii instead but the thought of a 1000 line haskell WM was just neat.
 
Stuff related to multiple screens iirc
 
@KevinMurphy var contents = window.contents = $('.target').val().replace(/n/g , " ");
 
user1596138
I'm so bad with DNS stuff :/
 
@Connor so after this, i should be able to use window.contents where ever, correct?
 
6:00 PM
@KevinMurphy yeah
 
m59
window.contents?
you gotta be doing something wrong, right?
 
user1125394
@Connor window.contents ouch is it good to do that?
 
m59
no
 
@FlorianMargaine The xinerama support is yet to be tested, I broke one of my two monitors, I'm going to pick up a few eventually and give it a shot.
 
m59
global all the things!
 
user1125394
6:01 PM
global is anal
 
@cx messy?
 
@m59 he could use a function to get the data
 
@Connor ok cool, all is working except my replace, for some reason shrugs and studies
 
m59
@connor that still makes no sense.
 
@Connor IE sucks and should be avoided all all costs
 
6:01 PM
@jbolanos i know
@KevinMurphy are you trying to replace new lines?
 
m59
oh hey @KevinMurphy! long time no see.
The replace doesn't work because you're not returning it to anything.
 
@m59 hey baby how are you?
 
m59
lol good.
Don't make my wife jealous :)
myVar = myVar.replace()
that's what you want.
 
@m59 thats what he has?
 
m59
wait, that whole thing is a mess.
I see, it's two lines.
My bad.
 
6:04 PM
this is all i have so far
window.contents = $('.target').val().replace(/n/g , ":");
document.getElementById('change').innerHTML = window.contents;
 
@KevinMurphy what are you trying to replace?
 
m59
You should do it piece by piece until you have it worked out
too much chanined, dude.
 
@Connor replacing new lines was just for testing, but i think it was a poor choice to test.
 
@m59 i told him to do that, because he had 2 vars, and i thought he had it worked out
 
m59
Also, you're using jquery already, so be consistent.
 
6:05 PM
@m59 what's inconsistent?
 
m59
.replace is being called on the target, I bet you.
do this
 
You're not replacing new lines there, only n
 
m59
var value = $('.target').val();
value = value.replace(//whatev);
$('#change').text(value);
 
Bad advice
 
m59
:(
 
6:07 PM
lmao
 
It's not the same behavior you know...
 
@FlorianMargaine you're getting married in 8 days?
 
m59
Oh, that's not what he's looking for?
 
but splitting up helps, indeed
@Connor yes
 
Congratulations!
 
m59
6:08 PM
grats @FlorianMargaine
 
@m59 use .html to replace innerhtml, not .text
 
m59
Ohhh
because he's removing lines?
wait...
I'm not sure what he's doing with that replace.
 
Because he's using innerhtml ~~
 
well i just realized my mistake with /n/g..
 
m59
6:09 PM
But WHY is he using innerHTML?
 
when he's using val();
 
window.contents = $('.target').val().replace(/a/g, "1"); - i'm replacing a string from a text box and placing it into an element
 
m59
val is the value of an input field...therefore text...no?
 
that should replace all a's with 1's, correct?
 
@KevinMurphy should
 
6:10 PM
@KevinMurphy you do know that in html, newlines are not the \n character, right?
 
m59
I don't see why use "html" on text
 
@FlorianMargaine yes, thanks :p
 
m59
am I still wrong??
 
anyways, the replace works, and it gets written into the correct element
now I just need to use it in zClip blah.
 
@m59 didn't know the context, I just saw the innerhtml replaced by a .text
 
m59
6:11 PM
Oh right, I'm not always wrong haha :)
 
user1125394
!!> "Kevin Murphy".replace(/n/g , ":")
 
@cx "Kevi: Murphy"
 
!!> hi, still banned?
 
@Connor "SyntaxError: missing ; before statement"
 
oohhhh
:)
!!undo
 
6:13 PM
@Connor I'm afraid I can't let you do that, Connor
 
paste.ubuntu.com/5989971 - is there anything obvious as to why the zClip script at the bottom doesn't work?
if i set copy to a string, it works just fine
 
@KevinMurphy maybe you're calling zclip too early?
 
hmm...
 
(When window.contents is still empty)
 
yeah, you're probably right. any suggestions?
 
6:16 PM
Call zclip from inside your doneTyping function
 
@What 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.
 
Hi, I'm working on stopwatch application with angular.js. How to format timer with angular.js? I tried with filter, but does not work.
 
@FlorianMargaine that did the trick - thanks!
 
@What You wan't to custom format it right? so why can't you use a filter?
 
@Connor Becouse if I use a filter, my application starts to lag...
 
6:27 PM
@What your doing something wrong then. make a fiddle
 
@connor ok. just a second...
 
6:39 PM
Hello, world:
Olinguito (Bassaricyon neblina), which is Spanish for "little olingo", is a mammal of the Bassaricyon genus. It is part of the Procyonidae family, which also include raccoons. Its discovery was revealed on 15 August 2013. Description The Olinguito is distinct from the olingo and the kinkajou. Its average weight is 2.5 lbs. The animal is omnivorous, eating fruits such as figs, nectar, and insects. The Olinguito is solitary and nocturnal. It produces a single offspring at a time. Distribution and habitat Specimens of the species have been identified from the cloud forest stretching from c...
 
ok so new guy isn't horrible
I was a little worried because of his age (old guy) but he seems alright.
I am ok with giving the ok
 
it's possible to do multiple string replacements in javascript, right? crosses fingers
 
@KevinMurphy what do you mean?
oh, like do replace(); more than once?
 
@Connor - In this example, how to filter time to minutes:seconds:milliseconds
http://jsfiddle.net/marolt93/A2EG5/
 
well in PHP i can say $string = hey baby, what's crackin'? and have array("a" => "1", "b" => "2") and just run one single str_replace with the string and array.
and it will replace all a's with 1's, and b's with 2's
 
6:45 PM
Do several replace calls, or make your own util function.
 
@KevinMurphy you can do replace().replace();
 
poop. i guess several replace calls it is! thanks @Zirak and @Connor
 
String.prototype.replaceAll = function (obj) {
	return Object.keys(obj).reduce(replacer, this);

	function replacer (ret, key) {
		var val = obj[key];
		return ret.replace(new RegExp(key, 'g'), val);
	}
};
 
@What so you haven't tried anything then?
 
@KevinMurphy Something like that ^ should do.
 
6:51 PM
oh my. how do i use that? :/
 
user1125394
copy/paste :)
 
hehe
 
user1125394
"poop".replaceAll({'o': 'e', 'p': 'l'});
 
0
Q: What should be the sense to use strict comparison to this specific string: 'final'

Daniel ArandaIn a code review that I was doing to a coworker, I said that here: if (someValue === 'final'){ There is no sense to use strict comparison because the only way to pass it as true is with other string value equals to final. I think that it is enough: if (someValue == 'final'){ His argument...

0
Q: WebStorm JavaScript code style: how to modify rules for comma first? (and how does this look?)

fusioSo I just recently discovered this comma first code style and I quite like it. Here is an example: var componentSchema = new Schema( { name: String , desc: String } , { collection : 'components' , discriminatorKey : '_type' } ) var c...

 
6:52 PM
yes I had..
I wrote this filter...
angular.module('pgdFilters', []).filter('cas', function() {
return function(input) {
var a = Math.floor(input/100);
var b = Math.floor(input/100);

if(a.length == 1) {
a = '0' + a;
}

return '00:' + a + ',' + b;
};
});
 
@cx thanks - could you explain what the purpose of String.prototype is?
@Zirak you're the bomb dot com
 
user1125394
!!tell cx mdn prototype
 
@cx Command murphy does not exist.
 
@What I don't think integers have a length...
 
6:54 PM
i try to get the progress of an ajax call with $.ajax()
what's the simplest way to get the percentage?
 
user1125394
new LoadingProgressListener() {}
 
user1125394
nah that's some java shit :)
 
@KevinMurphy Do you understand how it works?
 
@Zirak not fully, but i've been looking it over since you pasted it
 
@MikeBoutin you can only fake it I believe
 
6:56 PM
Hit me up if you don't
 
@mikedidthis i don't want to fake it lol
 
user1125394
then you should do it twice, first time to know approximately the time of that ajax call
 
@MikeBoutin What kind of "progress" are you talking about? Like, actual percentage progress?
 
@Zirak i can't seem to find docs on .reduce()
 
!!tell KevinMurphy mdn Array.reduce
 
you can't have a percentage on an infinite number.
 
It's the single greatest function known to man. After the Y-Combinator.
 
@mikedidthis I'm just trying to figure out exactly what he wants. Because it could be as simple as checking the status of the request.
 
@Zirak awesome, thanks :D can i ask you for some advice?
 
Like, and onreadystatechange kind of thing.
 
6:59 PM
@RyanKinal no probs. I replied to the wrong person anyway :D
 
@RyanKinal yes the percent progress
 
Since I don't know what the advise is on, I can't quite know
 
user1125394
!!> 'Zirak'.split('').reduce(function(l){return l+' ';}, '')
 
@cx " "
 
@MikeBoutin No can do.
 

« first day (1034 days earlier)      last day (3930 days later) »