Over HERE I wrote a simple script using Virchanza's walk-through to grab Videos from Firefox's cache folder. Normally if I seen a video I liked it was as easy as going to the /tmp folder and retrieving it, however something got broke somewhere using this method.
Andrew over at www.webupd8.org wrote a really cool script that solves this problem, and what makes his script even better, is the capability of saving those dreaded _CACHE_001_ files. You can find Andrew's script HERE. Below is his script using SMplayer replacing vlc.
#!/bin/bash
FLASH_TMP=`ls /tmp | grep Flash*`
if [[ $FLASH_TMP ]]; then
mplayer /tmp/Flash*
else
if [[ `ps x | awk '/libgcflashplayer.so\ /{print $1}'` ]]; then
flashvids() { lsof -p `ps x | awk '/libgcflashplayer.so\ /{print $1}'` -n 2>/dev/null | perl -lne '@F = split(/ +/, $_, 9); print "/proc/$F[1]/fd/${\($F[3] =~ /(^\d+)/)[0]}" if $F[4] eq "REG" && $F[8] =~ /\(deleted\)$/'; }
else
flashvids() { lsof -p `ps x | awk '/libflashplayer.so\ /{print $1}'` -n 2>/dev/null | perl -lne '@F = split(/ +/, $_, 9); print "/proc/$F[1]/fd/${\($F[3] =~ /(^\d+)/)[0]}" if $F[4] eq "REG" && $F[8] =~ /\(deleted\)$/'; }
fi
cp $(flashvids) ~/Desktop/flashvideo.flv
fi
Another thing I normally would do is pause what ever video I'm watching from various sites and open it up from the /tmp folder with SMplayer. Luckily Andrew covered that area as well, its as easy as changing the last line from.
cp $(flashvids) ~/Desktop/flashvideo.flv to smplayer $(flashvids)
Just create a Launcher for instant fun.
Thankyou Andrew for this great script, it has been really helpful to me and I'm sure an overwhelming amount of others. Please visit http://www.webupd8.org
Source