<?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>Antanova Ltd. &#187; twitter</title>
	<atom:link href="http://antanova.com/tags/twitter/feed" rel="self" type="application/rss+xml" />
	<link>http://antanova.com</link>
	<description>We make excellent websites</description>
	<lastBuildDate>Thu, 15 Sep 2011 21:23:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.3</generator>
		<item>
		<title>Twitter status text links made clickable</title>
		<link>http://antanova.com/blog/code-bits/twitter-status-text-links-made-clickable</link>
		<comments>http://antanova.com/blog/code-bits/twitter-status-text-links-made-clickable#comments</comments>
		<pubDate>Tue, 23 Feb 2010 15:35:55 +0000</pubDate>
		<dc:creator>Jason C</dc:creator>
				<category><![CDATA[Code-bits]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://antanova.com/?p=446</guid>
		<description><![CDATA[I needed to transform plain tweets into something clickable, so I made a JavaScript function for it.]]></description>
			<content:encoded><![CDATA[<p>A new design agency being formed by an existing client needed a site. They had a good design ready, I just had to build the thing. It&#8217;s built in WordPress, but I also pull in their Twitter stream on the client side.</p>
<p><a href="http://apiwiki.twitter.com/">Twitter&#8217;s api</a> is easy enough to use. I opted for the JSON-p format, but something I didn&#8217;t realise at the time was that the status updates are purely the plain text. So any URLs, usernames or hashtags are just plain text: no wrapping in &lt;a&gt;&lt;/a&gt; tags. It&#8217;s an easy problem to solve, though, and here it is for anyone else who needs it.</p>
<pre><code>function twitify( text )
{
    // replace urls with linked ones
    var t2 = text.replace(/(http|https)(:\/\/)([^ ]+)/ig, '&lt;a href="$1$2$3"&gt;$1$2$3&lt;/a&gt;' );

    // replace @username with clickable twitter link
    t2 = t2.replace(/@([^ ]+)/gi,'&lt;a href="http://twitter.com/$1"&gt;@$1&lt;/a&gt;');

    // replace hashtags with Twitter searches
    t2 = t2.replace(/#([^ ]+)/gi,'&lt;a href="http://search.twitter.com/search?q=%23$1"&gt;#$1&lt;/a&gt;');

    return t2;
}
</code></pre>
<p>So, feed the tweet into that function, and back out it comes with links, @users and #hastags made clickable.</p>
<p>Did I mention I ♥ regular expressions?</p>
]]></content:encoded>
			<wfw:commentRss>http://antanova.com/blog/code-bits/twitter-status-text-links-made-clickable/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>The power of Twitter</title>
		<link>http://antanova.com/blog/blogging/the-power-of-twitter</link>
		<comments>http://antanova.com/blog/blogging/the-power-of-twitter#comments</comments>
		<pubDate>Fri, 16 Oct 2009 17:09:45 +0000</pubDate>
		<dc:creator>Jason C</dc:creator>
				<category><![CDATA[Blogging]]></category>
		<category><![CDATA[media]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://antanova.com/?p=384</guid>
		<description><![CDATA[The Guardian thought they had been gagged. That was, until Twitter's users got involved.]]></description>
			<content:encoded><![CDATA[<p>The other day, the <a href="http://www.guardian.co.uk/media/2009/oct/12/guardian-gagged-from-reporting-parliament">Guardian reported that it had been gagged</a> from reporting on a parliamentary question, to be asked in the commons. It couldn&#8217;t say who had issued the &#8220;gagging order&#8221; (a.k.a. a &#8220;super injunction&#8221;), why it had been issued, and could only sneak out the fact that it existed because it was about parliamentary business.</p>
<p>This went out on a few <a href="http://boingboing.net">high profile blogs</a>, and spread from there. Eventually, after a few hours, the reason for the gag came out &#8211; I read about it first on Twitter. It was about a company that had dumped toxic waste off the Ivory Coast. Within hours, the name of the company and their solicitors (Trafigura and Carter-Ruck, respectively) were some of the most used words on Twitter. The culmination of all this attention was that Carter-Ruck withdrew their injunction, because of the huge publicity it was bringing to the story.</p>
<p>And that is the story of how Twitter broke a super-injunction. You can read a more full story <a href="http://www.guardian.co.uk/media/pda/2009/oct/13/twitter-online-outcry-guardian-trafigura">here with a very nice visualisation of the story as it developed</a>. Not bad considering most of the stuff on Twitter is about what some stranger&#8217;s cat&#8217;s had for dinner.</p>
]]></content:encoded>
			<wfw:commentRss>http://antanova.com/blog/blogging/the-power-of-twitter/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

