I configured Squid proxy and SquidGuard on a Ubuntu server VM and was curious as to how to write a url-rewrite that would append the safesearch ending to the end of Google searches. I grabbed a sample I found elsewhere, but it doesn't appear to work. I understand somebody is out there using it. Here is my sample rewrite syntax.

Code:
rewrite google {
    s@(google.com/search.*q=.*)@\1\&safe=active@i
    s@(google.com/images.*q=.*)@\1\&safe=active@i
    s@(google.com/groups.*q=.*)@\1\&safe=active@i
    s@(google.com/news.*q=.*)@\1\&safe=active@i
    s@(google.com/webhp.*)@\1\&safe=active@i
    s@(google.com/.*q=.*)@\1\&safe=active@i