Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Geolocation + OSM #1431

Open
SorinSu opened this issue Mar 31, 2022 · 0 comments
Open

Geolocation + OSM #1431

SorinSu opened this issue Mar 31, 2022 · 0 comments

Comments

@SorinSu
Copy link

SorinSu commented Mar 31, 2022

Hi,

i succeeded to use MB Geolocation + OSM but looking in code, i found out that the plugin is still loading google maps scripts, which is totally forbidden in Germany.
Moreover there is a warning in console "Google Maps JavaScript API warning: NoApiKeys..."

is there any workaround for this?

<?php
$metaBoxes[] = [
  'title' => __('Address'),
  'post_types' => ['company'],
  'id' => 'geolocation',
  'geo' => true,
  'fields' => [
    array(
      'type' => 'text',
      'name' => 'Address',
      'id'    => 'address'
    ),
    array(
      'type' => 'number',
      'name' => 'Postcode',
      'id'    => 'postcode',
      'placeholder' => 'Postcode*',
    ),
    array(
      'type' => 'text',
      'name' => 'house_number',
      'id'    => 'house_number',
      'placeholder' => 'house_number*',
    ),
    [
      'name' => 'Map',
      'type' => 'osm',
      'id'   => 'company_data_map',
      'language' => 'de-DE',
      'region' => 'DE',
      'address_field' => 'address',
    ],
  ],
];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant