Using regular expressions you can extract the username from a twitter URL. var twitterURL = item.link; var twitterName = twitterURL.match(/https?:\/\/(www\.)?twitter\.com\/(#!\/)?@?([^\/]*)/)[3];
![](http://johnsteinmetz.net/wp-content/uploads/2013/11/source-code-583537_1280.jpg)
Only have Sysomos tweet context? Extract username from URL.
Using regular expressions you can extract the username from a twitter URL.
var twitterURL = item.link;
var twitterName = twitterURL.match(/https?:\/\/(www\.)?twitter\.com\/(#!\/)?@?([^\/]*)/)[3];