WWWOFFLE tools

My WWWOFFLE tools. They at least work with WWWOFFLE Version 2.8.

Debian etc. users should export wwwoffle_cache=/var/cache/wwwoffle in .bash_profile.

Which of these are more debugged? The ones with higher Update Counts.

ModifyHTML

In wwwoffle.conf I can make the status of links show up even on a monochrome PDA with:

enable-modify-html=yes
anchor-requested-end=$R
anchor-cached-end=$

Failed POST insurance

In the script I use to call up my ISP, I have the following real life saver, as currently WWWOFFLE offers no built in protection for when your carefully typed in POST encounters a down server, etc. One merely has to move the failed O* and U* pair of files back into outgoing, and hope the server will be up next time you call. Repeat the process until one day they are back up.

set -eu #WWWOFFLE failed POSTs recourse insurance:
d=~jidanni/tmp/wwwoffle-outgoing-backup
test -d $d
find $d -type f -mtime +22 -exec mv {} /var/tmp \; #like rm
cd ${wwwoffle_cache-/var/spool/wwwoffle}/outgoing
set -- `wwwoffle-ls outgoing|
  awk '/POST/{m=$1;sub(/^O/,"U",$1);print m, $1}'`
test "$*"
cp -p $@ $d

We can also dig text out of a failed www-form-urlencoded POST with e.g.,

$ perl -MURI::Escape -pwe 'tr/+/ /; $_=uri_unescape($_); tr/\r//d'

Dan Jacobson

Last modified: 2009-01-20 23:00:56 +0800