#!/bin/sh
# htmlentities.sh
#
if [ $# -lt 1 ]
then
echo "usage: $0 textfile"
else
for item in $*
do
cp $item $item.bak
sed -f /etc/scripts/sedfile $item.bak > $item
rm $item.bak
done
fi
/etc/scripts/sedfile (remove the blank after the &!)
s/ä/\& auml;/g s/ö/\& ouml;/g s/ü/\& uuml;/g s/Ä/\& Auml;/g s/Ö/\& Ouml;/g s/Ü/\& Uuml;/g s/ß/\& szlig;/g