Trick for using Squid Proxy to access web page with character & in URL

The & character in URL will break the curl command in *nix shell due to its default behavior for background process. This trick solved my problem

[sourcecode]
url=’http://example.com?param1=value1&param2=value2′
curl –proxy squid-proxy-server-name:port-number $url
[/sourcecode]

Leave a Reply