in reply to Escaping '#' in a regexp

Lends itself to a one liner inplace edit (writes orig to orig.bak)

perl -pi.bak -e 's/background-color:\s*#(?:[0-9a-f]{6}|[0-9a-f]{3})\s* +;?/background-color: #FFFFFF;/i' <INFILE>

cheers

tachyon

s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print