diff options
Diffstat (limited to 'source/javascripts')
-rw-r--r-- | source/javascripts/twitter.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/javascripts/twitter.js b/source/javascripts/twitter.js index b1949913..975e7adb 100644 --- a/source/javascripts/twitter.js +++ b/source/javascripts/twitter.js @@ -140,7 +140,7 @@ var TwitterGitter = new Class({ //format linkify: function(text) { //courtesy of Jeremy Parrish (rrish.org) - return text.replace(/(https?:\/\/\S+)/gi,'<a href="$1">$1</a>').replace(/(^|\s)@(\w+)/g,'$1<a href="http://twitter.com/$2">@$2</a>').replace(/(^|\s)#(\w+)/g,'$1<a href="http://search.twitter.com/search?q=%23$2">#$2</a>'); + return text.replace(/(https?:\/\/[\w\-:;?&=+.%#\/]+)/gi,'<a href="$1">$1</a>').replace(/(^|\s)@(\w+)/g,'$1<a class="user" href="http://twitter.com/$2">@$2</a>').replace(/(^|\s)#(\w+)/g,'$1<a class="topic" href="http://search.twitter.com/search?q=%23$2">#$2</a>'); } }); //Compact Jsonp from http://clientcide.com/js |