Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I catch a click event on openlayers map and show a popup with featureinfo (if any) with position set as map.getLonLatFromPixel(new OpenLayers.Pixel(e.xy)). The user might set the map to show in fullscreen with a button, a little of JS code and some css styling:

#geomap_f, #mapbox_f {
    background: white;
    position: fixed !important;
    left: 0;
    top: 0;
    width: 100% !important;
    height: 100% !important;
    z-index: 49;

The problem arises when the user clicks the fullscreened map. The geoserver throws org.geoserver.platform.ServiceException: 979, 8330 not in dimensions of image: 1017, 943 and e.xy object holds some really huge numbers (979, 8330 in this case). I know I need to tell the map or the geoserver (or both) that the mapsize was changed and that I want them to recalculate the relationship between xy and latlon. I've tried using some of OpenLayers.Map methods with no success so far though. How can it be done? Do I need to resize the map differently? I already call map.updateSize() after resizing, that doesn't seem to influence the coordinates.

share|improve this question

For future use: It seems you have to make sure that the contents of the page fit to viewport before resizing a map to fullscreen. This can be easily done with JQuery.hide()/show() methods.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.