<html><head></head><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px"><div id="yiv0151417744"><div id="yui_3_16_0_ym19_1_1460029247076_16990"><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;" id="yui_3_16_0_ym19_1_1460029247076_16989"><div id="yiv0151417744"><div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12270"><div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12269" style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;"><div id="yiv0151417744"><div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_4686"><div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_4685" style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;"><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397">Hello Jeff,</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397"> Thank you for the reply. </div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397"> I'm pretty sure there's something I'm missing out here.</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397"><br clear="none"></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">In my map object I set my extent to:  (retrieved from ogrinfo -al -so )</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">       EXTENT 300000.000 4377000.000 304000.000 4380000.000</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">       UNITS meters</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">If I click on the lower left corner of the image for the first time, [mapx], [mapy] will give: 300000.000, 4377500.000</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">A click in the upper right corner gives me: 303500.000, 4380000.000</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">This doesn't seem pretty right.</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">I've set three projection objects, one in the map level and one on each layer with "init=epsg:2100".</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">[maplat], [maplon] also gives me wrong values with the same epsg, but 300 meters south than the [mapx], [mapx]</div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr">A first though would be that this should be a dataset problem </div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397" dir="ltr"><br></div><div id="yiv0151417744yui_3_16_0_ym19_1_1460025718171_4397">   </div><div class="yiv0151417744qtdSeparateBR" id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12271"><br clear="none"><br clear="none"></div><div class="yiv0151417744yqt0195477032" id="yiv0151417744yqt78411"></div></div></div></div><div class="yiv0151417744yqt5795345530" id="yiv0151417744yqt23599"><div class="yiv0151417744yqt1435746911" id="yiv0151417744yqt83493"><div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12268"> <div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12267" style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px;"> <div id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12266" style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px;"> <div dir="ltr" id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12349"><font size="2" face="Arial" id="yui_3_16_0_ym19_1_1460029247076_17031"> Στις 4:03 μ.μ. Τετάρτη, 6 Απριλίου 2016, ο/η Jeff McKenna <jmckenna@gatewaygeomatics.com> έγραψε:<br clear="none"></font></div>  <br clear="none"><br clear="none"> <div class="yiv0151417744y_msg_container" id="yiv0151417744yui_3_16_0_ym19_1_1460029247076_12265">Hi Stefanos,<br clear="none"><br clear="none">When I try this locally with CGI, I also get the same value on first <br clear="none">load for [mapx] and [mapy] of -1.0000,-1.0000 likely because there is no <br clear="none">point click yet.  But when I do click, the values for [mapx] and [mapy] <br clear="none">returned look valid.<br clear="none"><br clear="none">You might also want to check the returned values for [maplat] [maplon] <br clear="none">as well.<br clear="none"><br clear="none">If it is related to a projection issue, you might want to check the <br clear="none">mailing list archives for relevant discussions, such as <br clear="none"><a rel="nofollow" shape="rect" target="_blank" href="http://osgeo-org.1560.x6.nabble.com/retrieve-map-coordinates-with-different-EPSG-td5000369.html" id="yui_3_16_0_ym19_1_1460029247076_17965">http://osgeo-org.1560.x6.nabble.com/retrieve-map-coordinates-with-different-EPSG-td5000369.html</a><br clear="none"><br clear="none">I am testing with MS4W 3.1.3 (MapServer 7.0.1).<br clear="none"><br clear="none">-jeff<br clear="none"><br clear="none"><br clear="none">-- <br clear="none">Jeff McKenna<br clear="none">MapServer Consulting and Training Services<br clear="none"><a rel="nofollow" shape="rect" target="_blank" href="http://www.gatewaygeomatics.com/">http://www.gatewaygeomatics.com/</a><br clear="none"><br clear="none"><br clear="none"><br clear="none">On 2016-04-05 7:37 PM, Stefanos Anastasiou wrote:<br clear="none">>      Hello list.<br clear="none">><br clear="none">> I'm having a problem I can't understand where it's coming from. I'm<br clear="none">> using [mapx] and [mapy] parameters to get the coordinates of a simple<br clear="none">> click. When I click anywhere on the image, the resulting x,y is at least<br clear="none">> 1 kilometer North-West from where it should. The image coordinates look<br clear="none">> correct but the x,y are really wrong. I'm copying and pasting my form<br clear="none">> variables below:<br clear="none">><br clear="none">>   <form name="the_form" method=GET action="/cgi-bin/mapserv"><br clear="none">>                          <input type="hidden" name="imgext"<br clear="none">> value="[mapext]"><br clear="none">>                          <input type="hidden" name="map" value="[map]"><br clear="none">>                          <input type="image" name="img" src="[img]"<br clear="none">> width="700" height="500"><br clear="none">>                          <input type="hidden" name="zoomsize" value="2"><br clear="none">><br clear="none">><br clear="none">> When I first load the map with the following URL<br clear="none">> <a rel="nofollow" shape="rect" target="_blank" onclick="return theMainWindow.showLinkWarning(this)" href="http://127.0.0.1/cgi-bin/mapserv?map=/home/stefanos/mapdata/mymap.map">http://127.0.0.1/cgi-bin/mapserv?map=/home/stefanos/mapdata/mymap.map</a><br clear="none">> <<a rel="nofollow" shape="rect" target="_blank" onclick="return theMainWindow.showLinkWarning(this)" href="http://127.0.0.1/cgi-bin/mapserv?map=/home/stefanos/mapdata/trikala.map">http://127.0.0.1/cgi-bin/mapserv?map=/home/stefanos/mapdata/trikala.map</a>><div class="yiv0151417744yqt9385283269" id="yiv0151417744yqtfd32502"><br clear="none">><br clear="none">> x, y are set automatically in -1,000000 -1,000000.<br clear="none">><br clear="none">> Any idea?<br clear="none">><br clear="none">><br clear="none">><br clear="none">> Regards,<br clear="none">> Stefanos</div><br clear="none">><br clear="none"><br clear="none"><br clear="none"><br clear="none">_______________________________________________<br clear="none">mapserver-users mailing list<br clear="none"><a rel="nofollow" shape="rect" ymailto="mailto:mapserver-users@lists.osgeo.org" target="_blank" href="mailto:mapserver-users@lists.osgeo.org" id="yui_3_16_0_ym19_1_1460029247076_17967">mapserver-users@lists.osgeo.org</a><br clear="none"><a rel="nofollow" shape="rect" target="_blank" href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" id="yui_3_16_0_ym19_1_1460029247076_17966">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br clear="none"><br clear="none"></div>  </div> </div>  </div></div></div></div></div></div></div></div></div></div></body></html>