Okay I'm working on finding the latitude and longitude of cities using Perl. I found the Geo::Coder::Google module and have it installed properly, but I'm getting an error when attempting to use it. The first time I got the error I went out and got an API key from Google thinking that was what I was missing, but that didn't solve the error either. Can someone help me figure out what I'm missing?
Here is the error I'm receiving:
Google Maps API returned error: 500 Can't verify SSL peers without knowing which Certificate Authorities to trust at test.pl line 7.
Here is the code I'm using right now:
1:#!/usr/bin/perl
2:use strict;
3:use warnings;
4:
5:use Geo::Coder::Google;
6:my $geocoder = Geo::Coder::Google->new( apiver => 3, gl => 'us', apikey => 'My API Key Here' );
7:my $location = $geocoder->geocode( location => 'Mount Vernon, IN' );
8:
9:print "$location->{'geometry'}->{'location'}->{'lat'}";
10:print "$location->{'geometry'}->{'location'}->{'lng'}";