[Users] Map center inkorrekt
Andreas Hocevar
ahocevar at opengeo.org
Mon Jul 2 11:33:52 CEST 2012
You always need to provide coordinates in the map's projection, not in
geographic coordinates. This is true for both the center and the
bounds.
Andreas.
On Sun, Jul 1, 2012 at 10:36 AM, <mabra at manfbraun.de> wrote:
> Hello !
>
> I am completely new to ALL that ... so, it could be even
> my problem ...
>
> From the examples, I excerpted this code:
>
>
> Ext.onReady(function(){
> new GeoExt.MapPanel(
> {
> renderTo: "gxmap",
> width: 700,
> height: 700,
> layers: [new OpenLayers.Layer.OSM()],
> center: [8.5315623, 49.4100709],
> zoom: 6,
> map: {
> maxExtent: new OpenLayers.Bounds(-10000,
> -10000, 10000, 10000),
> units: "m",
> projection: "EPSG:900913"
> }
> });
> });
>
>
> The map is shown, but the center is Africa ;-)
> [Same temeperature here {this is Germany ;-) }].
>
> Some tips could help me - it#s just that in the moment,
> that I do not understand the coordinates, bounds etc.
> right.
>
> If I use a OpenLayer example for the same coords,
> it works. I even tried with zoom, this could influence
> it ??
>
> Thanks so far
> and best regards
>
> [Using Ext 3.3.2/ OpenLayers 2.10/2.12/ GeoExt stabile]
>
> ++mabra
>
>
>
>
> _______________________________________________
> Users mailing list
> Users at geoext.org
> http://www.geoext.org/cgi-bin/mailman/listinfo/users
--
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.
More information about the Users
mailing list