# scomp\_geomap\_geomap\_static

Source: https://zotonic.com/docs/2772/scomp_geomap_geomap_static

URI: https://zotonic.com/id/2772

Language: en



Render a static OpenStreetMap tile grid with a marker at a location.

```django
{% geomap_static latitude=52.34322 longitude=4.33423 zoom=14 %}
```

Alternatively, use a resource's computed coordinates:

```django
{% geomap_static id=id %}
```

| Argument                | Description                                                        | Default                                         |
| ----------------------- | ------------------------------------------------------------------ | ----------------------------------------------- |
| `latitude`, `longitude` | Explicit center coordinates in degrees.                            | Resource coordinates when `latitude` is absent. |
| `id`                    | Resource with `computed_location_lat` and `computed_location_lng`. | None.                                           |
| `zoom`                  | Tile zoom level.                                                   | `14`                                            |
| `n`                     | Default number of rows and columns.                                | `2`                                             |
| `rows`                  | Number of tile rows.                                               | `n`                                             |
| `cols`                  | Number of tile columns.                                            | `n`                                             |
| `size`                  | Display size of each tile in pixels.                               | `256`                                           |

When explicit latitude is present, both explicit coordinates are used; a missing longitude does not fall back to the resource. A resource need not belong to a particular category, but must supply usable computed coordinates. The tag emits an empty result when it cannot resolve a pair of floating-point coordinates.

The component renders `_geomap_static.tpl` with tile coordinates, center coordinates, grid dimensions, and marker offsets. The default template loads tiles from `https://tile.openstreetmap.org` and displays a marker. Override it in the site to customize presentation. The component declares `nocache` and does not generate or store a combined map image.

License: 

Attribution: 

Related resources: https://zotonic.com/api/agent/related/2772?language=en


## API access

- [API help](<https://zotonic.com/api-help>)
- [OpenAPI specification](<https://zotonic.com/openapi.json>)
- [This resource as JSON](<https://zotonic.com/api/agent/resource/2772?language=en>)
