If slashes cause a problem, change it to something that doesn't exist in the variable. sed (along with all the other implementations of stream editors) can use any characters as the delimiter, and in fact, whatever character follows the s is considered the delimiter.
> sed -e "s/floc/$floc/g" somefile > somefile.tmp
sed -e "s#floc#$floc#g" somefile > somefile.tmp
Blue skies... Todd
--
MandrakeSoft USA http://www.mandrakesoft.com
Easy things should be easy, and hard things should be possible.
--Larry Wall
Cooker Version mandrake-release-9.0-0.3mdk Kernel 2.4.19-12mdk
msg57846/pgp00000.pgp
Description: PGP signature
