my $url_param = 'http://www.whatzit.com?a=1&b=2'; my $url = "http:/www.xyzzy.com?url=" . uri_escape($url_param);