« first day (1570 days earlier)      last day (3384 days later) » 

1:00 PM
^ doesn't execute, does something strange instead.
 
ive made a fiddle
dont get how it can be undefined when both the stop, start methods are returned to the function
 
@BenjaminGruenbaum Nearly exactly what I did :D
 
@BenjaminGruenbaum That's because the HTML parser runs before JS
So </script> ends the script instantly.
 
I got it to properly insert the <script>, no dice
 
@Corbo152 like I said we know what's wrong with it, we're just not interested in telling you since we think you can figure it out just fine.
 
1:02 PM
And the weirdness happens because jsfiddle automagically inserts CDATA so that's what you see there
 
@Corbo152 isolate it a little bit further, you're missing exactly two characters :P
 
Guys, I've been hitting the wall for a while now. I'm getting pissed @ grunt and this is getting unhealthy. jsfiddle.net/b5yy2eu6 -- I just want it to output the result from .spawn() but it doesn't even say if it has an error or nay :|
 
@SecondRikudo odd, lol.
 
.innerHTML = "<script>alert('hi')<" + "/script>";
 
1:03 PM
So yeah, @KendallFrey, the only sequence which cannot appear directly in JavaScript is </script>
 
forget your broken code, try that
 
2 characters really ? god lol
 
jQuery has a workaround for it if I recall correctly where it will correctly run scripts (by selecting them and evaling them.
 
@KendallFrey I think it's not entirely possible
Let me do some checking
 
@KendallFrey is your code with the <script> tags coming from the server?
 
1:06 PM
@BenjaminGruenbaum It's inline
For simplicity
 
@BenjaminGruenbaum are the two characters im missing by anychance ()? lol
 
@Corbo152 :)
@KendallFrey inline as in it's inserted there by Razor or something of the sort right? (vs an AJAX call)
 
61
Q: Can scripts be inserted with innerHTML?

CraigI tried to load some scripts into a page using innerHTML on a <div>. It appears that the script loads into the DOM, but it is never executed (at least in Firefox and Chrome). Is there a way to have scripts execute when inserting them with innerHTML? Sample code: <!DOCTYPE html> <body onload="do...

@KendallFrey this suggests that it must run through eval() to actually work.
 
1 min ago, by Benjamin Gruenbaum
btw http://stackoverflow.com/q/1197575/1348195
 
Shut up
 
1:07 PM
@BenjaminGruenbaum now just to work out from where lmao
 
@BenjaminGruenbaum Could be :) The browser has no way of knowing
@Corbo152 If you'd stop lmaoing and start debugging, you'd have it solved in no time.
 
@KendallFrey well, it's an interesting problem I'll give you that. It seems like putting it in the <pre> initially, then copying it to the html area and running script tags is the most viable option.
 
@BenjaminGruenbaum Then I'd need to escape all the HTML :(
 
@KendallFrey why would you need to escape it?
 
Because it needs to be interpreted as text, not HTML
 
user4202350
1:11 PM
@BenjaminGruenbaum I did not anything but still people kick me here :(
 
@KendallFrey I don't see why that's a big problem, escaping and unescaping can be automatic. Templating engines already do it for you and when consuming it you just take the .textContent and set the .innerHTML
 
I'm not using a templating engine
I'm using a text editor
 
@ShaU woah, why were you suspended from SO for 3 days? Did you try cheating or something?
(Also, you probably can't respond anyway, so there's that - let me know in 3 days!)
 
@BenjaminGruenbaum Dat user profile
 
@KendallFrey I don't understand what you're saying here. If you want user input put it in a textarea or something - user input will be automatically escaped and you can access it with .value and set the .innerHTML based on that - the browser is quite capable of doing that conversion work for you.
 
1:14 PM
@BenjaminGruenbaum It's not user input, it's developer input
this is intended to be one big standalone page
 
@KendallFrey i am debugging and have been doing but when im getting no syntax errors and my JS syntax is shite... you have to laugh in these situations or youll go crazy
 
@KendallFrey The fundamental thing I'm trying to say here is that the browser will gladly and readily escape and unescape for you by getting from innerHTML and setting textConvent and vice versa.
 
careful about textContent
it doesn't keep newlines.
 
@BenjaminGruenbaum Right, but where do I get the string to put into textContent? A JS string literal?
@FlorianMargaine does for me
 
@FlorianMargaine are you sure you don't mean innerText?
 
1:16 PM
(in a <pre>)
 
@KendallFrey in your HTML, in a template tag for instance
 
@BenjaminGruenbaum yeh
@dystroy and I can confirm it
and dystroy surely has something similar in miaou
 
@BenjaminGruenbaum So I can store any HTML literally in a <template>, as long as it doesn't use <template>?
 
@KendallFrey Yes, <template> must be the root element IIRC
(I may be talking nonsense here)
 
@KendallFrey I think it works even if it uses template (since well... things can nest in HTML, you can have a div in a div). It puts it in a fragment for you.
 
1:19 PM
oh yeah, brilliant
I'll try it
will element ids in a template cause conflicts?
 
@KendallFrey No
 
It's a fragment, it's not actually part of the DOM. That's by design.
 
good
 
Note that template has shady browser support - that's worth mentioning.
 
Who wants to play my super buggy game made in 18 hours? You do. nickdugger.com/heliarena (apparently only works in chrome, or FF Developer edition, not regular FF)
 
1:22 PM
@FlorianMargaine I remember having written that exact comment but I can't remember in what project...
 
@NickDugger Why is it giving me a million alerts when I lose? Also - nice work.
 
@BenjaminGruenbaum It's a bug with a bullet hitting you multiple times instead of being removed after it hits you... sometimes it happens, sometimes it doesn't
I ran out of gamejam time
 
right iv placed () everywhere and everywhere throughout the stop method...its only.stop saying undefined as .start showing okat
 
@dystroy yeah, that's probably a copy paste of something in your code
 
@FlorianMargaine Found it. Not exactly in Miaou : github.com/Canop/Chrall/blob/master/chrome/chrall/…
 
1:25 PM
figured it out
 
@BenjaminGruenbaum According to MDN, everything but IE. Which is fine with me.
 
@KendallFrey great :)
@tereško did you quit?
 
@NickDugger FYI: Works fine in Opera
 
'Symbol' is undefined
 
1:26 PM
@KendallFrey opera is kinda like "chrome's developer edition"
 
Oh, the endgame alert seems to run in a loop
 
@KendallFrey it's because a bullet can bug out and hit you multiple times, firing the alert as many times as it hit you while it goes through your hitbox
 
I didn't know of the bug until I pushed it out the door and the gamejam ended
 
so... I think there's a pattern in where the ships come from
 
1:31 PM
lol, yeah, I noticed that too
 
(I just checked "block other alerts" to be able to play that long.)
but yeah, nice work
 
yeah, lol. I told you guys it was buggy :p it was my first game
 
not bad
notbadobama.jpg
 
I had to actually learn some math for it... lol
sin & cos became my enemies, but we eventually reached a truce once I got my hitbox in the right place
 
dont understand why at all now
alert_timer.stop(getKioskMessages);
stop: function() {
    clearInterval((this.alert_timer));
}
 
1:36 PM
Woohoo! Stuff happens! thanks @BenjaminGruenbaum @SecondRikudo
 
Any time :)
 
Here's some code that I wrote earlier, in the off chance that even one person is interested:
			function unindent(code)
			{
				var indent = code.match(/([\r\n]+)\s+/);
				if (indent === null)
				{
					return code;
				}
				return code.replace(new RegExp(indent[0], "g"), indent[1]).replace(/^[\r\n]+/, "");
			}
sorry about the ironic formatting
 
I have an odd question. When I was developing this game, and was writing ES6, with 6to5 and browserify, the transpiling worked perfectly fine, but then browserify would constantly fuck up; it would miss including files randomly. One save they would be fine, and the next, it would be missing entire modules.
 
@KendallFrey Up, CTRL+K several times until there are only 4 spaces, enter
 
Any clue why?
 
1:38 PM
@SecondRikudo tabs, brah
 
tabs are cancer.
2
 
@ThiefMaster you're cancer m8
 
@NickDugger Did you import something from 'something.js'?
Or import something from 'something'?
I don't know about CommonJS, but I know AMD fucks up the paths when you add the .js
 
@SecondRikudo the first one. Like I said, though, it worked fine sometimes, but randomly not other times
 
(It makes the absolute by default rather than relative by default)
 
1:40 PM
after spending an hour digging out half of my drive way, I think Ill take a snow day
 
Oh canada
 
drifts put 3-4 ft of snow down my driveway
 
Morning Bronadian
 
I live in an appt. so the driveway is like 100 meters
one of those ones that wraps around the building
ugh.
 
buy a snowblower
 
1:41 PM
I'm entirely sure that shoveling is your landlord's responsibility
 
I will when I'm not in an appt
@NickDugger it is
but if I wanna get to work I need a path to exit from
 
Submit a complaint, or something
 
three-point hitch pto snowblower is awesome
 
why?
 
Tell him he owes you a 6pack
or 10 marajuanas
 
1:42 PM
he hired a plow, it will get here at some point
 
i swear if i get this undefined not a function anymore im gonna flip... its clearly defined... even right click on the function call and go to definition and it finds it
 
Downside of working from home: No snow days.
Upside of working from home: No snow days.
 
@Corbo152 That generally indicates a scope problem
 
@Corbo152 link to your fiddle again?
 
1:44 PM
@SecondRikudo but both methods return a value to the function
 
@Corbo152 Can haz example?
 
> Fetal error
ehehehehe
 
This page has been created for the sole benefit of those people who purchase a computer and never bothers to read the instructions manual.... whats the point computers are plug and play
 
Why does your indentation look like shit?
WTF is that code doing anyway?
Is it just a setTimeout(alert, 2000, "Hello")?
 
1:48 PM
because thats how my VS formats it... no it sets a timeout on the function(getKioskMessages) which retrieves alerts for certain kiosks...
 
Why the hell is your comma on its own line? That super weird, man
 
Protip: Use the Tidy Up button before posting your JSFiddle.
 
formatting and refactoring will be done later... its just formatted like that coz VS.. ill refactor it using resharper when its working
 
you want people to help you, make your code readable to them
3
 
Why are you including jQuery 1.6?
 
1:50 PM
well, I'm snowed in
 
You need to read a JavaScript tutorial, or take a course.
 
is 8:50 am too early for beer?
 
@rlemon In fact formatting should never be delayed
 
@rlemon better drink a beer.
 
@rlemon which country?
 
1:51 PM
@Corbo152 Africa
 
@Corbo152 The one that invented snow
 
Africa invented snow in 1842, when Christoper Columbus flew the first airplane to the moon
 
@NickDugger Pfft, everyone knows that that's a myth and Columbus wasn't the first person to do that.
 
@BenjaminGruenbaum im not an idiot and most of the code i have written for this project works... however formatting issues etc.. you seem to frown on them quite bad
 
Amerigo Vespucci, eh? Am I right, or what, fellas?
 
1:53 PM
@Corbo152 That's how you recognize an experienced coder : he gets formatting and naming right before everything else
 
@Corbo152 I'm not calling you an idiot or criticizing you - I'm criticizing your code which is quite bad. Not sure what you're upset about you seemed to be well aware of that a while ago. I'm just giving you pointers.
 
@dystroy yes and i am not an experienced coder but everyone has to start somewhere dont they... i have written some quite good code
 
I've never written code I was satisfied with :(
Well, maybe once or twice, but that's about it.
 
Huh... I'm experienced-ish, but I claim that all of my code is garbage.
Good for you to be so confident lol
 
@BenjaminGruenbaum the reason jquery 1.6 was included is there was code involving selectors which i have now removed
 
1:55 PM
jQuery 1.6 is old.
 
and you don't need jQuery for selectors FWIW
 
u do for ie6
 
I use jQuery 1.7 in some projects here so there's that...
 
Best browser ever.
@RoelvanUden using old jquery in old projects is ok - there is rarely a good reason to migrate.
 
1:56 PM
Aye. I don't know about him; he might be working on 10-year old crap.
 
so this is not jquery then
$(this).closest
pretty sure it is
 
^ owned @rlemon
 
You don't NEED it, is what theyre saying
 
that is, but you said you used it for 'selectors'
 
This guy is trolling, bro
 
1:57 PM
@BenjaminGruenbaum drunk or bored?
 
It could be. We don't know what $ is. Could be Zepto.
 
@rlemon I have to study boring stuff :(
I wonder if I can kick myself or the system is foolproof against that hmm...
 
i think im gonna rewrite the code as two seperate functions one for stop and one for start
 
@BenjaminGruenbaum it tells you to take a walk
 
@Corbo152 You're wrapping already existing functionality for no reason.
@rlemon you tried it already :D?
 
1:59 PM
Zirak did first
 
lol cool.
 
like 2 minutes after we discovered it
"I know, I'll kick myself!"
 
yes but when i has two seperate functions i didnt get the undefined error lol
 
It was after I asked if it was possible. I get credit for it.
 
That's because you don't understand how this works in JS
 
2:00 PM
In your case, this === window
 
i know that
beacuse the long horn would be window.setinterval
namespace.function
 
Eh...? Namespace?
 
sorry thinking of C,
 
C has namespaces?
 
C#
 
2:03 PM
I don't often call a function on a namespace in C#... ;-)
 
no its classname.method
namespace is whats imported at the beginning
 
The imports are using :-P
Your terminology is a little shaky.
 
using system
 
lol. I think he didn't expect @RoelvanUden to know C# :P
 
i know they are using statements in VB they are imports
 
2:05 PM
VB... that explains everything
 
but whether its imports or using same thing
 
Huhn, I thought they were modules and references in VB.NET. But I'm no expert there, I could be far off.
Anyway, JS this is nothing like C#.
 
i know js.this
is the parent of clear interval
like you said in this case window
 
There is no sense in being precise when you don't even know what you're talking about - Von Neumann.
 
> Comcast sucks - Hitler
 
2:08 PM
> these pretzels are making me thirsty - cosmo
 
i^3 = em/x*65
 
@BenjaminGruenbaum really... life quotes?
 
@FlorianMargaine I hate it when people misquote me on the internet ~ Julius Caesar
8
 
lol
 
@Corbo152 it's not a life quote, you're trying to sound smart in front of us and @Roel about JS and .net where we really don't care if you're good in JS or C# or not - we just don't appreciate the BS. If you have a problem we can help you with that but we don't like people who try too hard to look clever :D
 
2:10 PM
what's the law when you don't want to be talked about on the internet, it actually amplifies the thing...
 
So - don't be that guy.
 
@FlorianMargaine not a law, it's the Streisand effect
 
@BenjaminGruenbaum im not trying to sound clever i know i am a beginner but i hate being talked down to by people with more experience
 
2:13 PM
Hello , Can somebody help . Whats the best way to parse xml data from back end in an angular app
 
The thing is we're really not trying to "talk down to you", when someone talks down to another person there is an implication they care about how they appear - we really don't care if you think of us as smart or stupid. We can help you with JS issues we just don't appreciate trying to sound smart :P
 
i am joining pluralsight and will be completing there tutorials
 
pluralsight is good
 
@32teeths you can .responseXML in an AJAX call, angular's $http doesn't support that directly so you can either make a native AJAX call (rather than $http) or parse it yourself (you can parse XML in JS)
 
Is it better to use some existing libraries . or build one
 
2:14 PM
@rlemond you have used it? it was recommended to me by a friend
 
var parser = new DOMParser;
parser.parseFromString(yourResponse, "text/xml"); // or something like that
 
crl
@32teeths (you don't need spaces before commas or dots)
 
I think that pluralsight's level is pretty low and they're not very good or accurate but the videos are supposed to be very helpful and tailored for beginners.
 
its better to convert it to json right ???
how do i do that
 
@BenjaminGruenbaum thanks... any other recommendations
 
2:16 PM
@BenjaminGruenbaum I didn't find accuracy to be an issue
 
@32teeths XML does not translate to JSON.
JSON can translate to XML, but not vice versa.
 
the video's were good. some of the tutorials were a bit dry
 
@Corbo152 As @BenjaminGruenbaum mentions, it doesn't matter if you're a beginner, veteran or nearly retired. What matters is being honest, and being explicit and clear in your questions, and showing an attitude willing to learn. I think your terminology is really shaky, and you're trying to "talk" your way out of it. That won't help you; there is nothing to be gained from that attitude. I've been learning about JS, seriously, for what, 6 months? These guys help you a lot; be open about it. ;-)
My 'pro-tip' :p
 
How do i handle the xml data to fill up the dom
then ?
i have done with json but not with xml
 
right ive just read up on js this used on methods
 
2:18 PM
Personally I don't learn, I'm just there to troll
 
@rlemon There was a site out there similar to dowebsitesneedtolookexactlythesameineverybrowser.com that's for using apostrophes for plural.
 
@32teeths you query the xml.
 
can u help ? being more elaborate
 
@SecondRikudo huh?
 
this is referring to the alert_timer
 
2:19 PM
we're still on that?!
 
so the error must be that the stop method is not returning anything to the alert_timer
 
> video's
 
@Corbo152 You probably want to really read this adequatelygood.com/JavaScript-Scoping-and-Hoisting.html
 
Thanks for noticing
 
2:21 PM
@NickDugger dangit, ninja'd
 
2:33 PM
posted on February 02, 2015 by Amaan Cheval

Read the Wikipedia page here. What it is A feral child (also called wild child) is a human child who has lived isolated from human contact from a very young age, and has little or no experience of human care, behavior, or, crucially, of human language. Some feral children have been confined by people (usually their own parents), and in some cases this child abandonment was due to the par

7
 
in an ember component how can I generate 6 things in the template, given a component propery called num with value 6?
 
down to just the start method
the alert is displaying undefined which means nothing is being returned?
 
anyone knows d3 chart??
 
@Feeds @SomeGuy it's because of the indian isn't it
 
@FlorianMargaine What?
 
2:47 PM
the 38 years guy
 
What about him?
 
he's indian
 
Are you asking if I wrote the post because of him?
 
Haha no
The first feral child I read about was Genie
Hadn't heard of the Indian until I wrote the post
 
2:49 PM
also
 
(Genie isn't in the article)
 
it's very hard to not read "fecal"
 
Hahaha
That hadn't happened to me yet, but I'm afraid it'll start now
 
> Fecal children lack the basic social skills
 
Hahaha
 
2:51 PM
> ... unable to learn to use a toilet
 
> Come to India you will find yourself confused there @FlorianMargaine
 
@FlorianMargaine Hahahahaha
 
@SomeGuy oh wow you wrote that? Thats kickass man
 
ok, that was racist :D
 
@FlorianMargaine Hahahaha I loved it
 
2:54 PM
> Itard
what a name
 
@Loktar Yeah, @BenjaminGruenbaum convinced me to finally start the blog
 
@Loktar doesn't sound weird in french tbf
 
ah I just think of retard, with i, so like an Apple expert is an iTard
 
yeah I know what you think :P
but that's not how we say it in french so...
 
le retard?
:P
 
2:56 PM
Hahahaha
 
Well french pronunciation is fucked up
 
Le bleh le blu
 
attardé
 
ahh
 
attardé attack
 
2:57 PM
lol
 
is all I can think of
 
I lol'd
 

« first day (1570 days earlier)      last day (3384 days later) »