Contact

admin
  • Skype
  • twitter
Feed Icon

Tags

Open Source Projects

Archives

Blogs of friends

Now playing [?]

  1. Chris Zippel – Surface
  2. Favourite Son – Sleeping on a plane (Bring ya love on down)
  3. Lux – 100 Billion Stars
  4. Sambox – Shikantaza
  5. Noah – Droid 9
Audioscrobbler/Last.fm

ClustrMap

RSS Enclosure Downloader In PowerShell

Posted in PowerShell at Friday, July 25, 2008 11:07 PM W. Europe Daylight Time

I used this one today to download all images of a Picasa album:

$feed=[xml](New-Object System.Net.WebClient).DownloadString("http://the/rss/feed/url")

foreach($i in $feed.rss.channel.item) {
	$url = New-Object System.Uri($i.enclosure.url)

	$url.ToString()
	$url.Segments[-1]

	(New-Object System.Net.WebClient).DownloadFile($url, $url.Segments[-1])
}