<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Stephen Belanger - Latest Comments</title><link xmlns="http://www.w3.org/2005/Atom" rel="http://api.friendfeed.com/2008/03#sup" href="http://disqus.com/sup/all.sup#forumcomments-6593925c" type="application/json"/><link>http://stephenbelanger.disqus.com/</link><description></description><atom:link href="http://stephenbelanger.disqus.com/comments.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Tue, 17 Jan 2012 12:56:22 -0000</lastBuildDate><item><title>Re: You are not lean, stop pretending.</title><link>http://stephenbelanger.com/2011/11/11/you-are-not-lean-stop-pretending/#comment-413533675</link><description>It's the curse of over-funded startups. Their impatience leads them to throw manpower at every "problem" they encounter, even if it's just a minor delay. They don't seem to get that, just like the system they are building; the more points of required communication between entities, the greater the latency will be per request.&lt;br&gt;&lt;br&gt;Adding a new person to a project slows everyone else down almost as much cumulatively as that person adds value.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Tue, 17 Jan 2012 12:56:22 -0000</pubDate></item><item><title>Re: A simple explanation of &amp;#8220;new&amp;#8221; in Javascript.</title><link>http://stephenbelanger.com/2011/04/10/a-simple-explanation-of-new-in-javascript/#comment-413353997</link><description>See this: &lt;br&gt;&lt;a href="http://stackoverflow.com/questions/2449254/what-is-the-instanceof-operator-in-javascript/2449264#2449264" rel="nofollow"&gt;http://stackoverflow.com/quest...&lt;/a&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jon H</dc:creator><pubDate>Tue, 17 Jan 2012 08:36:53 -0000</pubDate></item><item><title>Re: You are not lean, stop pretending.</title><link>http://stephenbelanger.com/2011/11/11/you-are-not-lean-stop-pretending/#comment-413351711</link><description>Heck of a post...I agree 100%.  I've seen large branded companies with 100s of developers and designers with horrible products.  It doesn't matter how much money or resources you have.  If you don't get it right with 1 person how are you ever going to get it right with 100s.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jon H</dc:creator><pubDate>Tue, 17 Jan 2012 08:32:23 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-386582775</link><description>It goes wherever your Socket.IO code is defined. I like to put it right after io.attach().</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Wed, 14 Dec 2011 12:52:25 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-386412699</link><description>Can anyone please tell me exactly the file name I should update it,  I don't know where to override this function?</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">hosam.ebrahim</dc:creator><pubDate>Wed, 14 Dec 2011 09:12:22 -0000</pubDate></item><item><title>Re: The Infinite Genies Paradox</title><link>http://stephenbelanger.com/2010/07/15/the-infinite-genies-paradox/#comment-380891526</link><description>The disney's genie is a little different from some of the other genies. Unlike the genie from aladdin, most genies seem to be tricky.  From what I remember when you wish a genie free, in exchange of that genie you are trapped and become a genie to take his/her place.(Or if the genie said a genie can only grant you three wishes would mean that it didn't matter which genie you asked the wish for. Kind of like an ATM machine where it doesn't matter which ATM you go to, you would still have the same amount of money) Also wishes can be interpreted differently, like I wish I had trillion dollars and the genie would give you trillion dollars worth of coin which crushes on top of you. As for the wishing the third wish to not be granted. The genie could simply vanish your existence from the beginning. By doing so, your wish would come true because you would have never wished for the wish and so there is no wish to come true. At the same time your wish didn't come true because although you never wished it the wish was granted. So it's kind of answering a paradox with a paradox. haha</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">picko</dc:creator><pubDate>Tue, 06 Dec 2011 23:50:40 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-378207952</link><description>Most of the "auto-scaling" cloud host type services can't give unique IPs though. Typically they are just a thin layer on top of AWS.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Sat, 03 Dec 2011 04:00:58 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-378207531</link><description>Umm .. it should work for vhosts if they have a dedicate IP. The problem was the clash of ports if both the tcp {} and http {} blocks were declared for all IPs.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Srirangan</dc:creator><pubDate>Sat, 03 Dec 2011 03:58:42 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-378207125</link><description>Yep, I've seen that fix too. Unfortunately, it doesn't work for vhosts. So cloud hosting services like dotcloud can't use that.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Sat, 03 Dec 2011 03:57:04 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-378206640</link><description>Hmm.. the way I got &lt;a href="http://Socket.io" rel="nofollow"&gt;Socket.io&lt;/a&gt; to work with Nginx at Review19 -- &lt;a href="http://review19.com" rel="nofollow"&gt;http://review19.com&lt;/a&gt; -- was to compile Nginx with the TCP Proxy module (&lt;a href="https://github.com/yaoweibin/nginx_tcp_proxy_module)" rel="nofollow"&gt;https://github.com/yaoweibin/n...&lt;/a&gt;. Didn't require any modifications of the &lt;a href="http://Socket.io" rel="nofollow"&gt;Socket.io&lt;/a&gt; code but I needed to declare an additional tcp {} block in nginx.conf</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Srirangan</dc:creator><pubDate>Sat, 03 Dec 2011 03:54:48 -0000</pubDate></item><item><title>Re: How to make Socket.IO work behind nginx (mostly)</title><link>http://stephenbelanger.com/2011/09/21/how-to-make-socket-io-work-behind-nginx-mostly/#comment-360164476</link><description>wow. i killed quite a bit of time trying to figure out why &lt;a href="http://socket.io" rel="nofollow"&gt;socket.io&lt;/a&gt; wasn't working on my server...and now i know. thanks so much for posting this.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jonathan youngblood</dc:creator><pubDate>Thu, 10 Nov 2011 12:19:20 -0000</pubDate></item><item><title>Re: A simple explanation of &amp;#8220;new&amp;#8221; in Javascript.</title><link>http://stephenbelanger.com/2011/04/10/a-simple-explanation-of-new-in-javascript/#comment-343724244</link><description>While we've already touched `instanceof` it might be worth mentioning that it's actually nothing more than a lookup in the prototype chain; basically, `a instanceof b` checks if the object a has b.prototype as its prototype, or if it's the "prototype of the prototype", and so on.&lt;br&gt;&lt;br&gt;This could lead to subtle problems, as in the following:&lt;br&gt;&lt;br&gt;    function Test() {}&lt;br&gt;    var test = new Test()&lt;br&gt;    test instanceof Test // true&lt;br&gt;    &lt;br&gt;    Test.prototype = {foo: 42};&lt;br&gt;    test instanceof Test // false&lt;br&gt;    test.foo // undefined (since Test.prototype doesn't refer to the [[Prototype]] of test)&lt;br&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jonas Höglund</dc:creator><pubDate>Tue, 25 Oct 2011 10:25:45 -0000</pubDate></item><item><title>Re: A simple explanation of &amp;#8220;new&amp;#8221; in Javascript.</title><link>http://stephenbelanger.com/2011/04/10/a-simple-explanation-of-new-in-javascript/#comment-343722151</link><description>Not necessarily; if you attempt to return anything but an object (for example a number), it'll still evaluate to the newly constructed object. `function Foo() {return 42}; (new Foo) instanceof Foo` evaluates to true.&lt;br&gt;&lt;br&gt;The best way to understand how `new` works would be to read the spec, but it can be a bit difficult to understand sometimes. However, if you actually want to know for sure how it works, I'd suggest checking there: &lt;a href="http://es5.github.com/#x13.2.2" rel="nofollow"&gt;http://es5.github.com/#x13.2.2&lt;/a&gt;&lt;br&gt;&lt;br&gt;    8. Let result be the result of calling the [[Call]] internal property of F, providing obj as the this value and providing the argument list passed into [[Construct]] as args.&lt;br&gt;    9. If Type(result) is Object then return result.&lt;br&gt;     10. Return obj.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jonas Höglund</dc:creator><pubDate>Tue, 25 Oct 2011 10:22:03 -0000</pubDate></item><item><title>Re: jquery.flash &amp;#8211; Who needs swfobject when you have this?</title><link>http://stephenbelanger.com/2009/10/04/jquery-flash-who-needs-swfobject-when-you-have-this/#comment-315642404</link><description>No, you'd have to do that in the swf itself. Javascript doesn't have any control of the playback of a swf file unless you explicitly expose that access in the swf itself. In which case, you might as well just use a container swf that loads other swfs as a sort of playlist.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Mon, 19 Sep 2011 23:59:02 -0000</pubDate></item><item><title>Re: jquery.flash &amp;#8211; Who needs swfobject when you have this?</title><link>http://stephenbelanger.com/2009/10/04/jquery-flash-who-needs-swfobject-when-you-have-this/#comment-315626261</link><description>Is it possible for this to monitor when the swf has completed and then start up a different swf file?</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Zibeo</dc:creator><pubDate>Mon, 19 Sep 2011 23:26:55 -0000</pubDate></item><item><title>Re: A simple explanation of &amp;#8220;new&amp;#8221; in Javascript.</title><link>http://stephenbelanger.com/2011/04/10/a-simple-explanation-of-new-in-javascript/#comment-308403151</link><description>I have been thinking about this a little. Perhaps an even simpler way to explain...&lt;br&gt;using the "new" keyword before a function automatically adds "return this;" at the end of the function if no return already exists. This way of thinking helps eliminate the confusing weird behavior "new" seems to have.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">chadams</dc:creator><pubDate>Tue, 13 Sep 2011 00:12:17 -0000</pubDate></item><item><title>Re: jquery.flash v1.3.1 &amp;#8211; Squashing IE-related bugs.</title><link>http://stephenbelanger.com/2010/01/02/jquery-flash-v1-3-1-squashing-ie-related-bugs/#comment-196679115</link><description>Good to know.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Tue, 03 May 2011 22:14:40 -0000</pubDate></item><item><title>Re: jquery.flash v1.3.1 &amp;#8211; Squashing IE-related bugs.</title><link>http://stephenbelanger.com/2010/01/02/jquery-flash-v1-3-1-squashing-ie-related-bugs/#comment-196660145</link><description>I did some more testing. It appears to be bug in FireFox. IE &amp;amp; Chrome do not exhibit this behavior. See: &lt;a href="https://bugzilla.mozilla.org/show_bug.cgi?id=654241" rel="nofollow"&gt;https://bugzilla.mozilla.org/s...&lt;/a&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">PaulCormier</dc:creator><pubDate>Tue, 03 May 2011 21:15:32 -0000</pubDate></item><item><title>Re: jquery.flash v1.3.1 &amp;#8211; Squashing IE-related bugs.</title><link>http://stephenbelanger.com/2010/01/02/jquery-flash-v1-3-1-squashing-ie-related-bugs/#comment-196635961</link><description>Sorry, have been busy with other things.  I looked at it a bit but couldn't find anything. I might have some time to take another look at it this weekend. I wasn't able to reproduce the bug in Chrome, so it's possible that it is a Firefox issue.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Tue, 03 May 2011 20:00:16 -0000</pubDate></item><item><title>Re: jquery.flash v1.3.1 &amp;#8211; Squashing IE-related bugs.</title><link>http://stephenbelanger.com/2010/01/02/jquery-flash-v1-3-1-squashing-ie-related-bugs/#comment-193373375</link><description>Any progress on this bug?</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">PaulCormier</dc:creator><pubDate>Thu, 28 Apr 2011 11:29:18 -0000</pubDate></item><item><title>Re: jquery.flash v1.3.1 &amp;#8211; Squashing IE-related bugs.</title><link>http://stephenbelanger.com/2010/01/02/jquery-flash-v1-3-1-squashing-ie-related-bugs/#comment-190673438</link><description>Hi Stephen,&lt;br&gt;&lt;br&gt;thank you very much for this plugin. I'm using it for displaying Flash-Banners on a Typo3-Site. It's working great!&lt;br&gt;&lt;br&gt;Nevertheless, I had some problems to create a proper count on Flash-Banner-Clicks. This is a general problem with the Flash-Technology, so the only chance you have is using an EVENT inside the surrounding Tag. Because each banner has to have an unique count, you will want to work with parameters to guarantee a valid identification.&lt;br&gt;&lt;br&gt;Therefore, I added an onmousedown-Event for the Object-Tag in your plugin-code. Now, it's quite easy to call another javascript-function, that does the job (in my case, it's an AJAX-driven MySQL-Insert).&lt;br&gt;&lt;br&gt;You may download the zipped files here, if you like:&lt;br&gt;&lt;a href="http://imageco.de/jquery.flash.zip" rel="nofollow"&gt;http://imageco.de/jquery.flash...&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;HTML-Snippet to give you an idea what  I'm talking about:&lt;br&gt;&lt;br&gt;######## jquery.flash ########&lt;br&gt;&amp;lt;script&amp;gt;&lt;br&gt;	$(document).ready(&lt;br&gt;											function () {&lt;br&gt;												$(\'#add_'.$row["UID_PL"].'\').flash( &lt;br&gt;												{&lt;br&gt;													\'src\':\''.$img_pfad.$row["file"].'\',&lt;br&gt;													\'id\': \'flash_'.$row["UID_PL"].'\',&lt;br&gt;													\'onmousedown\': \'javascript: bannerCount('.$row["UID_PL"].')\',&lt;br&gt;													\'width\': \'160\',&lt;br&gt;													\'height\': \'600\',&lt;br&gt;													\'wmode\': \'transparent\'&lt;br&gt;												}&lt;br&gt;												);&lt;br&gt;											}&lt;br&gt;);&lt;br&gt;&amp;lt;/script&amp;gt;&lt;br&gt;&lt;br&gt;&amp;lt;div id="add_'.$row[" uid_pl"].'"=""&amp;gt;You need to install flash.&amp;lt;/div&amp;gt;';			&lt;br&gt;&lt;br&gt;######## jquery.flash end ########		&lt;br&gt;&lt;br&gt;&lt;br&gt;I hope, my solution can help other people too. &lt;br&gt;Please excuse my bad english, I'm still learning :)&lt;br&gt;&lt;br&gt;Cheers&lt;br&gt;&lt;br&gt;Uwe&lt;br&gt;&lt;br&gt;&lt;br&gt;														&lt;br&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Uwe Jakobs</dc:creator><pubDate>Sat, 23 Apr 2011 09:08:32 -0000</pubDate></item><item><title>Re: A simple explanation of &amp;#8220;new&amp;#8221; in Javascript.</title><link>http://stephenbelanger.com/2011/04/10/a-simple-explanation-of-new-in-javascript/#comment-182183318</link><description>One small tweak - if the constructor returns an object then it will be returned instead of 'this'.&lt;br&gt;&lt;br&gt;e.g. change "return name" to "return {a:12}" and you will find:&lt;br&gt;&lt;br&gt;var test = new Test('test');&lt;br&gt;test instanceof Test; // returns false&lt;br&gt;&lt;br&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrew</dc:creator><pubDate>Sun, 10 Apr 2011 19:03:23 -0000</pubDate></item><item><title>Re: JSGame &amp;#8211; Game development in Javascript!</title><link>http://stephenbelanger.com/2010/03/30/jsgame-game-development-in-javascript/#comment-178386037</link><description>cool animated background - very impressive :)&lt;br&gt;&lt;br&gt;very distracting when you're reading though...&lt;br&gt;&lt;br&gt;good luck with JSGame, I found you whilst doing research for my own similar project.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">phobius</dc:creator><pubDate>Tue, 05 Apr 2011 01:55:59 -0000</pubDate></item><item><title>Re: The Infinite Genies Paradox</title><link>http://stephenbelanger.com/2010/07/15/the-infinite-genies-paradox/#comment-172154036</link><description>Impossible, yes. But what I'm demonstrating is what SHOULD have been impossible but isn't.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stephen Belanger</dc:creator><pubDate>Sat, 26 Mar 2011 02:20:05 -0000</pubDate></item><item><title>Re: The Infinite Genies Paradox</title><link>http://stephenbelanger.com/2010/07/15/the-infinite-genies-paradox/#comment-172152547</link><description>"For my third wish, I ask that you not grant my third wish."&lt;br&gt;This could be used, even if you are only given 1 wish. Less intricate, more impossible than the model above.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Blop386</dc:creator><pubDate>Sat, 26 Mar 2011 02:09:38 -0000</pubDate></item></channel></rss>
