Title: Simple Fields Map extension
Author: Pär Thernström
Published: <strong>2012-08-23</strong>
Last modified: 2013-12-18

---

Szukaj wtyczek

![](https://ps.w.org/simple-fields-map-extension/assets/banner-772x250.png?rev=594467)

Wtyczka **nie została przetestowana z trzema ostatnimi głównymi wydaniami WordPressa**.
Może nie być już utrzymywana lub obsługiwana, co może skutkować problemem ze zgodnością
z nowszymi wersjami WordPressa.

![](https://s.w.org/plugins/geopattern-icon/simple-fields-map-extension_d8dde0.svg)

# Simple Fields Map extension

 Autor: [Pär Thernström](https://profiles.wordpress.org/eskapism/)

[Pobierz](https://downloads.wordpress.org/plugin/simple-fields-map-extension.1.3.4.zip)

 * [Szczegóły](https://pl.wordpress.org/plugins/simple-fields-map-extension/#description)
 * [Recenzje](https://pl.wordpress.org/plugins/simple-fields-map-extension/#reviews)
 * [Rozwój](https://pl.wordpress.org/plugins/simple-fields-map-extension/#developers)

 [Wsparcie](https://wordpress.org/support/plugin/simple-fields-map-extension/)

## Opis

Adds a new field type to [Simple Fields](https://wordpress.org/extend/plugins/simple-fields/)
that let you choose a location.

The coordinates (lat/lng) of that location is saved
 and easily retrieved in for
example your theme.

Happy geocoding!

#### Features

 * Easily add maps to any post, page or custom post type
 * Integrates seamlessly into Simple Fields
 * You can have multiple maps with separately settings
 * Each map can have it’s own:
    - zoom level
    - map type (Roadmap, Satellite, Hybrid, Terrain)
    - default location
 * Search location of address by using built in search box
 * Search location by enter its latitude and longitude coordinates
 * Supports Repeatable Fields – have any amount of maps connected to each post
 * From each saved position you can get
    - Latitude and Longitude
    - Address information, including store/shop name if that was what the user searched
      for when adding this location
    - Preferred zoom level

#### To add a map to a field group programmatically

Slug for this field extension is „googlemaps”.

Full example using register field group:

    ```
    <?php

    // Add a field group with a Google Map-field
    simple_fields_register_field_group('sf_map_test_field_fg',
        array(
            'name' => 'My map',
            'slug' => "mu_map"
            'repeatable' => 1,
            'fields' => array(
                array(
                    "type" => "googlemaps",
                    "slug" => "sf_map",
                    "name" => "Test map",
                    "options" => array(
                        "defaultZoomLevel" => 10,
                        "defaultMapTypeId" => "HYBRID", // ROADMAP | SATELLITE | HYBRID | TERRAIN
                        "defaultLocationLat" => 40.71435,
                        "defaultLocationLng" => -74.00597,
                        "defaultZoomLevel" => 10
                    )
                )
            )
        )
    );

    ?>
    ```

#### Translations/Languages

This plugin is available in the following languages:

 * English

### Usage

 1. (Make sure you have Simple Fields installed)
 2. Install the Simple Fields Maps Extension plugin
 3. You will find the Map field in the usual settings page of Simple Fields

## Zrzuty ekranu

[⌊The field with its options⌉⌊The field with its options⌉[

The field with its options

[⌊The post edit screen, including the currently selected coordinates and a search
result found⌉⌊The post edit screen, including the currently selected coordinates
and a search result found⌉[

The post edit screen, including the currently selected coordinates and a search 
result found

[⌊Example of the values that are being stored for each saved location/field (and
the function used to get them)⌉⌊Example of the values that are being stored for 
each saved location/field (and the function used to get them)⌉[

Example of the values that are being stored for each saved location/field (and the
function used to get them)

## Recenzje

Wtyczka nie ma jeszcze żadnej recenzji.

## Kontrybutorzy i deweloperzy

„Simple Fields Map extension” jest oprogramowaniem open source. Poniższe osoby miały
wkład w rozwój wtyczki.

Zaangażowani

 *   [ Pär Thernström ](https://profiles.wordpress.org/eskapism/)
 *   [ Earth People ](https://profiles.wordpress.org/earth-people/)

[Przetłumacz wtyczkę “Simple Fields Map extension” na swój język.](https://translate.wordpress.org/projects/wp-plugins/simple-fields-map-extension)

### Interesuje cię rozwój wtyczki?

[Przeglądaj kod](https://plugins.trac.wordpress.org/browser/simple-fields-map-extension/),
sprawdź [repozytorium SVN](https://plugins.svn.wordpress.org/simple-fields-map-extension/)
lub czytaj [dziennik rozwoju](https://plugins.trac.wordpress.org/log/simple-fields-map-extension/)
przez [RSS](https://plugins.trac.wordpress.org/log/simple-fields-map-extension/?limit=100&mode=stop_on_copy&format=rss).

## Rejestr zmian

#### 1.3.4

 * Use better default values so plugin does not break if you don’t enter a default
   zoom level or map type.

#### 1.3.3

 * Load scripts over HTTPS. Fixes https://wordpress.org/support/topic/javascript-
   blocked-map-not-showing.

#### 1.3.2

 * Fixed strict standards warning

#### 1.3.1

 * Static maps did not care about any preferred zoom level that was set in GUI. 
   Now they do, funky funky!

#### 1.3

 * Add dropdown to select preferred zoom level for each map
 * Show notice in admin if user does not have Simple Fields installed

#### 1.2.2

 * Fixed notice error if no additional image sizes where used in the theme currently
   in use

#### 1.2.1

 * Added support for coordinates with negative latitude/longitude locations, like
   this one: 2.033630,-76.007050
 * Added version number to scripts/styles to cache bust.

#### 1.2

 * Added support for adding marker by entering its lng/lat coordinates. Valid formats
   are: 48.858278,2.294254 or 48.858278 2.294254
 * Made plugin translatable

#### 1.1.6

 * Fixed a bug with the latest version of Simple Fields

#### 1.1.5

 * It’s tricky to create to class because Simple Fields must be added/loaded already
   when creating the class. The modified solution works, but perhaps only on specific
   versions of PHP. Have to check this in more details…

#### 1.1.4

 * A marker/location can now be removed/unset.
    This is useful if you have a map
   field added to all your posts, but wan’t to exclude the map for a single post.
   This is also the default behavior, so a post don’t not risk being saved with 
   the wrong position (or at least the risk is lower).

#### 1.1.3

 * Autocomplete was out of control when using repeatable fields. It’s now back in
   control.

#### 1.1.2

 * The search box is now much better. It can search for Places, i.e. establishments,
   geographic locations, or prominent points of interest.
 * Return values now return much more info if the location was selected through 
   the new autocomplete place search. The return array now also have:
    - The name of the selected place
    - The formatted address of the place
    - A address_components-object thas has (according to Google): a „collection 
      of address components for this Place’s location”

#### 1.1.1

 * Modified the way args are passed with return_values, since wp_parse_args don’t
   work recursive.

#### 1.1.0

 * Added static maps to return values.

#### 1.0.2

 * Clearified the fact that you need the latest version of Simple Fields.

#### 1.0.1

 * Typos in readme

#### 1.0

 * Version 1. It works and it’s groovy!

## Meta

 *  Wersja **1.3.4**
 *  Ostatnia aktualizacja **13 lat temu**
 *  Włączone instalacje **100+**
 *  Wersja WordPressa ** 3.8 lub nowszej **
 *  Testowano do **3.7.41**
 *  Język
 * [English (US)](https://wordpress.org/plugins/simple-fields-map-extension/)
 * Tagi
 * [geolocation](https://pl.wordpress.org/plugins/tags/geolocation/)[Google Maps](https://pl.wordpress.org/plugins/tags/google-maps/)
   [latitude](https://pl.wordpress.org/plugins/tags/latitude/)[longitude](https://pl.wordpress.org/plugins/tags/longitude/)
   [simple fields](https://pl.wordpress.org/plugins/tags/simple-fields/)
 *  [Widok zaawansowany](https://pl.wordpress.org/plugins/simple-fields-map-extension/advanced/)

## Oceny

 5 na 5 gwiazdek.

 *  [  4 recenzje 5-gwiazdkowe     ](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/?filter=5)
 *  [  0 recenzji 4-gwiazdkowych     ](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/?filter=4)
 *  [  0 recenzji 3-gwiazdkowych     ](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/?filter=3)
 *  [  0 recenzji 2-gwiazdkowych     ](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/?filter=2)
 *  [  0 recenzji 1-gwiazdkowych     ](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/?filter=1)

[Twoja opinia](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/#new-post)

[Zobacz wszystkierecenzje.](https://wordpress.org/support/plugin/simple-fields-map-extension/reviews/)

## Zaangażowani

 *   [ Pär Thernström ](https://profiles.wordpress.org/eskapism/)
 *   [ Earth People ](https://profiles.wordpress.org/earth-people/)

## Wsparcie

Masz coś do dodania? Potrzebujesz pomocy?

 [Zobacz forum wsparcia](https://wordpress.org/support/plugin/simple-fields-map-extension/)

## Złóż datek

Czy chcesz wesprzeć rozwój wtyczki?

 [ Wspomóż wtyczkę ](http://earthpeople.se/)