将邮政编码转换为经度和纬度

时间:2017-04-20 11:26:25

标签: api google-maps csv latitude-longitude zipcode

我想将zipcode转换为经度和纬度并写入csv文件。我使用谷歌的storelocator,我只需要用zipcode放置标记...

for (var i = 1, row; row = rows[i]; i++) {
    row = this.toObject_(headings, this.parseRow_(row));
    var features = new storeLocator.FeatureSet;
    features.add(this.FEATURES_.getById('Wheelchair-' + row.Wheelchair));
    features.add(this.FEATURES_.getById('Audio-' + row.Audio));

    var position = new google.maps.LatLng(row.Ycoord, row.Xcoord);


    var shop = this.join_([row.Shp_num_an, row.Shp_centre], ', ');
    var locality = this.join_([row.Locality, row.Postcode], ', ');

    var store = new storeLocator.Store(row.uuid, position, features, {
        title: row.titre,
        address: this.join_([shop, row.Street_add, locality], '<br>'),
        hours: row.Hrs_of_bus
    });
    stores.push(store);
}

0 个答案:

没有答案