How do I fingerprint a dynamic URL?

Yahoo! Pipes: How can I extract the most recent URL from an RSS feed and assign that to a fixed short URL?

  • I want to bookmark the most recent "minute by minute" report from the Guardian - so that I don't have to go to their category page to find it. I thought I could set up a short URL and then change the URL that that points to - so that it always points to the URL of the most recent minute by minute report. Can I do this with Yahoo pipes? I would need to get the relevant RSS feed (http://www.guardian.co.uk/football/football+tone/minutebyminute/rss), and extract the URL of the most recent story. Then I need to get a fixed short URL (EG http://bit.ly/shortguardianurl) and dynamically change what long URL this points to, so that it always points to the URL extracted from the RSS feed ....

  • Answer:

    http://bit.ly won't let you overwrite an existing redirect. You could use this Yahoo! Pipe I made: http://pipes.yahoo.com/pipes/pipe.info?_id=89e1c78fd6258beee98dab37fe4b7a56 and then host your own redirect with this PHP script: <?php $links = simplexml_load_file('http://pipes.yahoo.com/pipes/pipe.run?_id=89e1c78fd6258beee98dab37fe4b7a56&_render=rss'); foreach ($links->channel->item as $item) { $link = $item->title ; } header( "Location: ".$link ) ; ?> Then you could just bookmark that PHP page and it'll always redirect you to the latest story. Keep in mind, Yahoo! Pipes isn't always dependable, so you might just want to do the whole thing with PHP like this: <?php $mylink= array(); $links = simplexml_load_file('http://www.guardian.co.uk/football/football+tone/minutebyminute/rss'); foreach ($links->channel->item as $item) { $link = $item->link ; $mylink = array(0=>$link); break; } header( "Location: ".$mylink[0] ) ; ?>

Darren Levy at Quora Visit the source

Was this solution helpful to you?

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.