开发者

Using Yahoo Pipes to makes tweets link to url they contain rather than Twitter

I'm wondering how you can use Yaho开发者_C百科o Pipes to get any tweets than contain a url to link to that url when clicked, instead of linking to Twitter.


I made some assumptions.

  • You want the first URL if there are multiple links in the message
  • If there is no URL, you will skip the tweet
  • You only care about http and https links

The flow ends up:

  • 1 Fetch Feed - Use twitter RSS
  • 2 Filter - item.description Matches regex https?://
  • 3 Rename - item.description Copy As link
  • 4 Regex - In item.link replace ^.*?(https?://[\w:#@%/;$()~?+-=\.&]+).*$ with $1 (s)

If you want to see all tweets, then the simplest thing is to split the feed at the top and filter the ones with and without URLs and only process the URL ones. Finally you can remerge the feeds before outputting.

If you want more url types, change the https?:// to (https?|ftp|etc):// in step 2 and 4

I made a sample here.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜