SVN: toys/rsget.pl/Image/ImageShack
sparky
sparky at pld-linux.org
Thu Jun 3 18:37:09 CEST 2010
Author: sparky
Date: Thu Jun 3 18:37:08 2010
New Revision: 11500
Modified:
toys/rsget.pl/Image/ImageShack
Log:
- fixes/updated
- allow more uris
- detect "file not found"
Modified: toys/rsget.pl/Image/ImageShack
==============================================================================
--- toys/rsget.pl/Image/ImageShack (original)
+++ toys/rsget.pl/Image/ImageShack Thu Jun 3 18:37:08 2010
@@ -10,18 +10,21 @@
web: "http://imageshack.us/"
tos: "http://reg.imageshack.us/content.php?page=rules"
uri: qr{profile\.imageshack\.us/user/.*?/images/detail/#\d+/.+}
-uri: qr{(?:img\d+\.)imageshack\.us/i/.+/}
+uri: qr{(?:img\d+\.)imageshack\.us/(?:i/.+/|my\.php\?image=.+)}
slots: max
status: OK 2010-03-11
unify:
return "http://img$1.imageshack.us/i/$2/"
- if m{http://profile\.imageshack\.us/user/.*?/images/detail/#(\d+)/(.+)};
+ if m{http://profile\.imageshack\.us/user/.*?/images/detail/#(\d+)/(.+)}
+ or m{http://img(\d+)\.imageshack\.us/my\.php\?image=(.+)};
start:
GET( $-{_uri} );
- ! m{<a href="(.*?)" target="_blank".*class="last">\s*<img title="Zoom"};
+ ERROR( "file not found" ) if $-{_referer} eq "http://www.imageshack.us/";
+
+ ! m{src="(.*?)" alt="click to zoom"};
my $file_uri = de_ml( $1 );
( my $fname = $file_uri ) =~ s{.*/}{};
More information about the pld-cvs-commit
mailing list