<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>dev.enekoalonso.com &#187; internet</title>
	<atom:link href="http://dev.enekoalonso.com/tag/internet/feed/" rel="self" type="application/rss+xml" />
	<link>http://dev.enekoalonso.com</link>
	<description>having fun with code</description>
	<lastBuildDate>Wed, 12 Oct 2011 21:40:17 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>Date from ISO 8601 string</title>
		<link>http://dev.enekoalonso.com/2010/09/21/date-from-iso-8601-string/</link>
		<comments>http://dev.enekoalonso.com/2010/09/21/date-from-iso-8601-string/#comments</comments>
		<pubDate>Tue, 21 Sep 2010 16:17:34 +0000</pubDate>
		<dc:creator>Eneko Alonso</dc:creator>
				<category><![CDATA[uncategorized]]></category>
		<category><![CDATA[date]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[explorer]]></category>
		<category><![CDATA[format]]></category>
		<category><![CDATA[internet]]></category>
		<category><![CDATA[iso]]></category>
		<category><![CDATA[iso8601]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[parse]]></category>
		<category><![CDATA[parts]]></category>
		<category><![CDATA[standard]]></category>
		<category><![CDATA[titanium]]></category>

		<guid isPermaLink="false">http://dev.enekoalonso.com/?p=662</guid>
		<description><![CDATA[Javascript is full of surprises and browser compatibility is even more exciting. For some reason, I thought all browsers or Javascript engines had support for creating dates from ISO 8601 strings. Like this: var myDate = new Date&#40;&#34;2010-09-21T02:57:00Z&#34;&#41;; console.log&#40;myDate&#41;; // Mon Sep 20 2010 19:57:00 GMT-0700 (Pacific Daylight Time) Turns out that does not work [...]]]></description>
			<content:encoded><![CDATA[<p>Javascript is full of surprises and browser compatibility is even more exciting. For some reason, I thought all browsers or Javascript engines had support for creating dates from ISO 8601 strings. Like this:</p>
<div class="geshi no javascript">
<ol>
<li class="li1">
<div class="de1"><span class="kw2">var</span> myDate = <span class="kw2">new</span> Date<span class="br0">&#40;</span><span class="st0">&quot;2010-09-21T02:57:00Z&quot;</span><span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">console.<span class="me1">log</span><span class="br0">&#40;</span>myDate<span class="br0">&#41;</span>; <span class="co1">// Mon Sep 20 2010 19:57:00 GMT-0700 (Pacific Daylight Time)</span></div>
</li>
</ol>
</div>
<p>Turns out that does not work on Internet Explorer (tested on IE8). It didn&#8217;t work in Titanium Developer either, when I was working on an iPhone/Android app a couple of weeks ago. Here is the function I used to load dates from ISO 8601 strings:</p>
<div class="geshi no javascript">
<ol>
<li class="li1">
<div class="de1"><span class="kw2">function</span> dateFromISO8601<span class="br0">&#40;</span>isostr<span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;<span class="kw2">var</span> parts = isostr.<span class="me1">match</span><span class="br0">&#40;</span><span class="re0">/\d+/g</span><span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp;<span class="kw1">return</span> <span class="kw2">new</span> Date<span class="br0">&#40;</span>parts<span class="br0">&#91;</span><span class="nu0">0</span><span class="br0">&#93;</span>, parts<span class="br0">&#91;</span><span class="nu0">1</span><span class="br0">&#93;</span> &#8211; <span class="nu0">1</span>, parts<span class="br0">&#91;</span><span class="nu0">2</span><span class="br0">&#93;</span>, parts<span class="br0">&#91;</span><span class="nu0">3</span><span class="br0">&#93;</span>, parts<span class="br0">&#91;</span><span class="nu0">4</span><span class="br0">&#93;</span>, parts<span class="br0">&#91;</span><span class="nu0">5</span><span class="br0">&#93;</span><span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1"><span class="br0">&#125;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="kw2">var</span> myDate = dateFromISO8601<span class="br0">&#40;</span><span class="st0">&quot;2010-09-21T02:57:00Z&quot;</span><span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">console.<span class="me1">log</span><span class="br0">&#40;</span>myDate<span class="br0">&#41;</span>; <span class="co1">// Mon Sep 20 2010 19:57:00 GMT-0700 (Pacific Daylight Time)</span></div>
</li>
</ol>
</div>
<p>That should work fine everywhere :)</p>
<h3  class="related_post_title">Related Posts:</h3><ul class="related_post"><li>June 14, 2011 -- <a href="http://dev.enekoalonso.com/2011/06/14/titanium-studio-and-titanium-mobile-1-7/" title="Titanium Studio and Titanium Mobile 1.7">Titanium Studio and Titanium Mobile 1.7</a> (0)</li><li>September 17, 2010 -- <a href="http://dev.enekoalonso.com/2010/09/17/mootools-core-for-server-and-mobile-development/" title="MooTools Core for Server and Mobile Development">MooTools Core for Server and Mobile Development</a> (1)</li><li>July 30, 2010 -- <a href="http://dev.enekoalonso.com/2010/07/30/titanium-developer-love-and-hate/" title="Titanium Developer: love and hate">Titanium Developer: love and hate</a> (3)</li><li>August 18, 2010 -- <a href="http://dev.enekoalonso.com/2010/08/18/titanium-developer-love-and-hate-part-ii/" title="Titanium Developer: love and hate (Part II)">Titanium Developer: love and hate (Part II)</a> (0)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://dev.enekoalonso.com/2010/09/21/date-from-iso-8601-string/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Playing with WebSockets</title>
		<link>http://dev.enekoalonso.com/2010/05/03/playing-with-websockets/</link>
		<comments>http://dev.enekoalonso.com/2010/05/03/playing-with-websockets/#comments</comments>
		<pubDate>Tue, 04 May 2010 04:20:37 +0000</pubDate>
		<dc:creator>Eneko Alonso</dc:creator>
				<category><![CDATA[uncategorized]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[connection]]></category>
		<category><![CDATA[game]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[internet]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[socket]]></category>
		<category><![CDATA[studio]]></category>
		<category><![CDATA[tpc]]></category>
		<category><![CDATA[visual]]></category>
		<category><![CDATA[websocket]]></category>
		<category><![CDATA[websockets]]></category>

		<guid isPermaLink="false">http://dev.enekoalonso.com/?p=521</guid>
		<description><![CDATA[Today I spent some time with Tim at work, playing with WebSockets, a new HTML5 feature that only Google Chrome supports so far. WebSockets allow browsers to create and maintain open direct TCP connections to the server, allowing instant communication in both directions. This means that ajax polling is no longer needed to get updates [...]]]></description>
			<content:encoded><![CDATA[<p>Today I spent some time with Tim at work, playing with <a href="http://en.wikipedia.org/wiki/Web_Sockets">WebSockets</a>, a new <a href="http://dev.w3.org/html5/websockets/">HTML5 feature</a> that only Google Chrome supports so far. WebSockets allow browsers to create and maintain open direct TCP connections to the server, allowing instant communication in both directions. This means that ajax polling is no longer needed to get updates from the server. Instead, the server can send a message directly to the browser at any point in time while the connection is open. Awesome!</p>
<p style="text-align: left;">Since we are currently working on a C# .Net project, we searched Internet and found this very cool example that we took as a base for a little multiuser game we were working on today: <a href="http://www.codeproject.com/KB/webservices/c_sharp_web_socket_server.aspx">WebSocket Chat</a></p>
<p style="text-align: left;"><a href="http://www.codeproject.com/KB/webservices/c_sharp_web_socket_server.aspx"></a><br />
<a href="http://www.codeproject.com/KB/webservices/c_sharp_web_socket_server.aspx"><img class="aligncenter" src="http://www.codeproject.com/KB/webservices/c_sharp_web_socket_server/WebSocketServer.png" alt="" /></a></p>
<p>The potential of WebSockets is incredible, specially for online games and multiuser applications.</p>
<h3  class="related_post_title">Related Posts:</h3><ul class="related_post"><li>May 22, 2010 -- <a href="http://dev.enekoalonso.com/2010/05/22/more-websockets-now-with-python/" title="More WebSockets, now with Python!">More WebSockets, now with Python!</a> (9)</li><li>May 12, 2011 -- <a href="http://dev.enekoalonso.com/2011/05/12/angry-birds-as-a-web-app/" title="Angry Birds as a Web App">Angry Birds as a Web App</a> (0)</li><li>June 8, 2010 -- <a href="http://dev.enekoalonso.com/2010/06/08/change-in-websockets-handshake-protocol/" title="Change in WebSockets handshake protocol">Change in WebSockets handshake protocol</a> (0)</li><li>May 6, 2010 -- <a href="http://dev.enekoalonso.com/2010/05/06/tech-talks-at-level-studios/" title="Tech talks at LEVEL Studios">Tech talks at LEVEL Studios</a> (0)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://dev.enekoalonso.com/2010/05/03/playing-with-websockets/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Google Fiber in San Luis Obispo? That would be awesome!</title>
		<link>http://dev.enekoalonso.com/2010/02/18/google-fiber-in-san-luis-obispo-that-would-be-awesome/</link>
		<comments>http://dev.enekoalonso.com/2010/02/18/google-fiber-in-san-luis-obispo-that-would-be-awesome/#comments</comments>
		<pubDate>Thu, 18 Feb 2010 16:52:44 +0000</pubDate>
		<dc:creator>Eneko Alonso</dc:creator>
				<category><![CDATA[uncategorized]]></category>
		<category><![CDATA[access]]></category>
		<category><![CDATA[calpoly]]></category>
		<category><![CDATA[connection]]></category>
		<category><![CDATA[fiber]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[internet]]></category>
		<category><![CDATA[network]]></category>
		<category><![CDATA[san luis obispo]]></category>
		<category><![CDATA[slo]]></category>

		<guid isPermaLink="false">http://dev.enekoalonso.com/?p=467</guid>
		<description><![CDATA[It looks like the nomination for San Luis Obispo to get Google Fiber is gaining a lot of support. I have no idea how other cities or communities are doing, but here at SLO seems like a lot of people is getting involved. Having Google Fiber in San Luis Obispo would be awesome. There is [...]]]></description>
			<content:encoded><![CDATA[<p>It looks like the nomination for San Luis Obispo to get Google Fiber is gaining a lot of support. I have no idea how other cities or communities are doing, but here at SLO seems like a lot of people is getting involved. Having Google Fiber in San Luis Obispo would be awesome.</p>
<p>There is a group on Facebook (<a href="http://www.facebook.com/group.php?gid=303673457163">Bring Google Fiber to San Luis Obispo</a>) with more than 1300 members right now, mostly from the tech companies and <a href="http://www.calpoly.edu/">CalPoly</a>.</p>
<p><center><a href="http://www.facebook.com/group.php?gid=303673457163"><img alt="" src="http://photos-h.ak.fbcdn.net/hphotos-ak-snc3/hs147.snc3/17464_1253092960766_1032780133_566408_4228578_n.jpg" title="Bring Google Fiber to San Luis Obispo" class="alignnone" width="360" height="288" /></a></center></p>
<p>If you want to nominate San Luis Obispo, please <a href="http://www.google.com/appserve/fiberrfi/public/options">do it here</a>.</p>
<h3  class="related_post_title">Related Posts:</h3><ul class="related_post"><li>May 3, 2010 -- <a href="http://dev.enekoalonso.com/2010/05/03/playing-with-websockets/" title="Playing with WebSockets">Playing with WebSockets</a> (4)</li><li>September 21, 2010 -- <a href="http://dev.enekoalonso.com/2010/09/21/date-from-iso-8601-string/" title="Date from ISO 8601 string">Date from ISO 8601 string</a> (1)</li><li>July 30, 2010 -- <a href="http://dev.enekoalonso.com/2010/07/30/creating-qr-codes-with-google-charts-api/" title="Creating QR Codes with Google Charts API">Creating QR Codes with Google Charts API</a> (1)</li><li>May 16, 2010 -- <a href="http://dev.enekoalonso.com/2010/05/16/performance-matters/" title="Performance matters">Performance matters</a> (2)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://dev.enekoalonso.com/2010/02/18/google-fiber-in-san-luis-obispo-that-would-be-awesome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

