aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormatthew <matthew>2007-07-07 11:35:36 +0000
committermatthew <matthew>2007-07-07 11:35:36 +0000
commitb6d8ee14555d1c02bf6b3a1a79dcdad96db72d65 (patch)
tree17e0886b8b81c5c6bb186d4deb8b24c7ea5e7811
parent58438bc2a2c6690b7a472a4b5d49f95f8fe528d2 (diff)
Ignore multiple strings.
-rwxr-xr-xweb/index.cgi3
1 files changed, 2 insertions, 1 deletions
diff --git a/web/index.cgi b/web/index.cgi
index 6588a254f..74c2ede08 100755
--- a/web/index.cgi
+++ b/web/index.cgi
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: index.cgi,v 1.149 2007-07-07 11:32:45 matthew Exp $
+# $Id: index.cgi,v 1.150 2007-07-07 11:35:36 matthew Exp $
use strict;
require 5.8.0;
@@ -862,6 +862,7 @@ sub geocode_string {
my $s = shift;
$s = lc($s);
$s =~ s/[^-&0-9a-z ']/ /g;
+ $s =~ s/\s+/ /g;
$s = uri_escape($s);
$s =~ s/%20/+/g;
my $url = 'http://maps.google.com/maps/geo?q=' . $s;