Sometimes you would want to download files from rapidshare via the commandline because the webinterface sucks. Did I say sometimes? You *never* want to use the webinterface 🙂
You have to have a premium account to use it.
$user = $ARGV;
$pass = $ARGV;
$file = $ARGV;
`mkdir ~/.cookies; wget --save-cookies ~/.cookies/rapidshare --post-data "login=$user&password=$pass" -O - https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi > /dev/null`;
next if /^$/;
print `wget -c --load-cookies ~/.cookies/rapidshare $_`;