From chandrakant.dinni at edurite.com Sun Apr 1 21:47:01 2012 From: chandrakant.dinni at edurite.com (Chandrakant Dinni) Date: Mon, 2 Apr 2012 10:17:01 +0530 Subject: [mapserver-users] MapServer CGI 5.6.6 and MapServer CGI 6.0.2 image quality varies. In-Reply-To: References: Message-ID: Hi, The attached images are from same map files (bluemarble imagery from http://visibleearth.nasa.gov/view.php?id=57752) . 1)Improper_Mapserver5.6.6.JPG?the colours are not smooth,the picture is pixellated in Mapserver 5.6.6 2) Proper_Mapserver6.0.2.JPG??the colours are smooth in Mapserver 6.0.2. How can I make the image show properly in 5.6.6, what makes the difference ? Tried using untiled images but the result is the same in 5.6.6.There could me some mapserver setting or preprocessing to be done on image files. Right now I am doing only this to get the final images. gdal_translate -co TILED=YES land_shallow_topo_8192.tif land_shallow_topo_8192_TILED.tif gdaladdo --config GDAL_CACHEMAX 1500 -r average land_shallow_topo_8192_TILED.tif 4 8 16 32 64 128 256 Also any know any better\more detailed sources for public domain atlas images,I am also using http://www.naturalearthdata.com/ as a source of data. Thanks in advance....I am planning to use Mapserver 5.6.6 because the Fusion JavaScript Client is compatible with 5.6.6. I am using ms4w for testing ,though final server will be on linux. Below is the map file. MAP ? ? NAME "BlueMarble" PROJECTION # "init=EPSG:4326" "proj=latlong" END ? ? STATUS ON ? ? SIZE 10800 5400 ? ? EXTENT -180 -90 180 90 ? ? UNITS DD ? ? SHAPEPATH "../NaturalEarth" # don't need background colour ? ? # IMAGECOLOR 128 128 255 ? ? # ? ? # Start of web interface definition ? ? # ? ? WEB ? ? ? ? IMAGEPATH "/ms4w/tmp/ms_tmp/" ? ? ? ? IMAGEURL "/ms_tmp/" METADATA "wms_title" ? ? ? ? ? "WMS Server" "wms_onlineresource" "http://172.16.1.126/cgi-bin/mapserv.exe?map=/ms4w/data/mapfiles/bluemarble.map&" "wms_extent" ?"-180 -90 180 90" "wms_enable_request" ?"*" END ? ? END # WEB LAYER ? ? ?NAME "NasaBlueMarbleOffline" ? ? ?DATA "./bluemarble/land_shallow_topo_8192_TILED.tif" STATUS ON ? ? ?TYPE RASTER ? ? ?PROJECTION ? ? ? ?"proj=latlong" ? ? ?END ? ? ?METADATA "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" ? ? ? ?"wms_title" "Nasa Blue Marble Offline" ? ? ?END END LAYER NAME "world_land" DATA "./50m_physical/50m_land.shp" STATUS OFF TYPE POLYGON OPACITY 100 CLASS NAME 'Land Outline' STYLE OUTLINECOLOR 184 ?138 ?0 END # STYLE END # CLASS METADATA "wms_title" "Land Outline" END END # LAYER LAYER NAME "world_freshwater_bodies" DATA "./50m_physical/50m_rivers_lake_centerlines.shp" STATUS OFF TYPE LINE OPACITY 100 CLASS NAME 'Fresh Water Bodies' STYLE OUTLINECOLOR 51 ?102 ?255 END # STYLE END # CLASS METADATA "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" "wms_title" "Freshwater Bodies Of The World" END END # LAYER LAYER NAME "world_lakes" DATA "./50m_physical/50m_lakes.shp" STATUS OFF TYPE POLYGON OPACITY 100 CLASS NAME 'Lakes' STYLE COLOR 0 61 245 END # STYLE END # CLASS METADATA "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" "wms_title" "Lakes Of The World" END END # LAYER LAYER NAME "geographic_points" DATA "./50m_physical/50m_geography_regions_points.shp" STATUS OFF TYPE POINT OPACITY 50 CLASS LABEL COLOR ?0 0 0 OUTLINECOLOR 255 255 255 FONT "sans" TYPE truetype SIZE 6 POSITION AUTO PARTIALS FALSE END END # CLASS METADATA "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" "wms_title" "Major Geographic Points" END END # LAYER LAYER NAME "countries" DATA "./country2007/cntry07_econ.shp" STATUS OFF TYPE POLYGON CLASS NAME 'The Countries Of The World' STYLE OUTLINECOLOR 0 0 0 END # STYLE END # CLASS METADATA "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" "wms_title" "The Countries Of The World" END END # LAYER LAYER NAME "state_lines_usa" DATA "./50m_cultural/ne_50m_admin_1_states_provinces_shp.shp" STATUS OFF TYPE POLYGON CLASS NAME 'States Lines USA' STYLE OUTLINECOLOR 0 0 0 END # STYLE END # CLASS METADATA "wms_title" "States Lines USA" END END # LAYER LAYER NAME "urban_areas" DATA "./50m_cultural/ne_50m_urban_areas.shp" STATUS OFF TYPE POLYGON CLASS NAME 'Urban Areas' STYLE OUTLINECOLOR 0 0 0 END # STYLE END # CLASS METADATA "wms_title" "Urban Areas" END END # LAYER #LAYER # NAME "populated_places" # DATA "./50m_cultural/ne_50m_populated_places.shp" # STATUS OFF # TYPE POINT # # # METADATA # "wms_title" "Populated Places" # END # #END # LAYER END # MAP Regards, Dinni. -------------- next part -------------- A non-text attachment was scrubbed... Name: Improper_Mapserver5.6.6.JPG Type: image/jpeg Size: 4488 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Proper_Mapserver6.0.2.JPG Type: image/jpeg Size: 3537 bytes Desc: not available URL: From thomas.bonfort at gmail.com Sun Apr 1 22:41:27 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Mon, 2 Apr 2012 07:41:27 +0200 Subject: [mapserver-users] MapServer CGI 5.6.6 and MapServer CGI 6.0.2 image quality varies. In-Reply-To: References: Message-ID: how are you requesting the image ? you can add this to your mapfile: outputformat name "aggjpeg" driver "AGG/JPEG" mimetype "image/jpeg" imagemode rgb end On Mon, Apr 2, 2012 at 06:47, Chandrakant Dinni wrote: > Hi, > > The attached images are from same map files (bluemarble imagery from > http://visibleearth.nasa.gov/view.php?id=57752) . > > 1)Improper_Mapserver5.6.6.JPG?the colours are not smooth,the picture > is pixellated in Mapserver 5.6.6 > 2) Proper_Mapserver6.0.2.JPG??the colours are smooth in Mapserver 6.0.2. > > How can I make the image show properly in 5.6.6, what makes the difference ? > Tried using untiled images but the result is the same in 5.6.6.There > could me some mapserver setting or preprocessing to be done on image > files. > > Right now I am doing only this to get the final images. > gdal_translate -co TILED=YES land_shallow_topo_8192.tif > land_shallow_topo_8192_TILED.tif > gdaladdo --config GDAL_CACHEMAX 1500 -r average > land_shallow_topo_8192_TILED.tif 4 8 16 32 64 128 256 > > Also any know any better\more detailed sources for public domain atlas > images,I am also using http://www.naturalearthdata.com/ as a source of > data. > Thanks in advance....I am planning to use Mapserver 5.6.6 because the > Fusion JavaScript Client is compatible with 5.6.6. don't know the specifics of fusion, but if it's javascript only I don't think it wouldn't work with 6.0. regards, thomas > > I am using ms4w for testing ,though final server will be on linux. > Below is the map file. > > MAP > ? ? NAME "BlueMarble" > PROJECTION > # "init=EPSG:4326" > "proj=latlong" > END > ? ? STATUS ON > ? ? SIZE 10800 5400 > ? ? EXTENT -180 -90 180 90 > > ? ? UNITS DD > ? ? SHAPEPATH "../NaturalEarth" > # don't need background colour > ? ? # IMAGECOLOR 128 128 255 > > ? ? # > ? ? # Start of web interface definition > ? ? # > ? ? WEB > ? ? ? ? IMAGEPATH "/ms4w/tmp/ms_tmp/" > ? ? ? ? IMAGEURL "/ms_tmp/" > METADATA > "wms_title" ? ? ? ? ? "WMS Server" > "wms_onlineresource" > "http://172.16.1.126/cgi-bin/mapserv.exe?map=/ms4w/data/mapfiles/bluemarble.map&" > "wms_extent" ?"-180 -90 180 90" > "wms_enable_request" ?"*" > END > ? ? END # WEB > > LAYER > ? ? ?NAME "NasaBlueMarbleOffline" > ? ? ?DATA "./bluemarble/land_shallow_topo_8192_TILED.tif" > STATUS ON > ? ? ?TYPE RASTER > ? ? ?PROJECTION > ? ? ? ?"proj=latlong" > ? ? ?END > > ? ? ?METADATA > "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" > ? ? ? ?"wms_title" "Nasa Blue Marble Offline" > ? ? ?END > END > LAYER > NAME "world_land" > DATA "./50m_physical/50m_land.shp" > STATUS OFF > TYPE POLYGON > OPACITY 100 > CLASS > NAME 'Land Outline' > STYLE > OUTLINECOLOR 184 ?138 ?0 > END # STYLE > END # CLASS > METADATA > "wms_title" "Land Outline" > END > END # LAYER > LAYER > NAME "world_freshwater_bodies" > DATA "./50m_physical/50m_rivers_lake_centerlines.shp" > STATUS OFF > TYPE LINE > OPACITY 100 > CLASS > NAME 'Fresh Water Bodies' > STYLE > OUTLINECOLOR 51 ?102 ?255 > END # STYLE > END # CLASS > METADATA > "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" > "wms_title" "Freshwater Bodies Of The World" > END > END # LAYER > LAYER > NAME "world_lakes" > DATA "./50m_physical/50m_lakes.shp" > STATUS OFF > TYPE POLYGON > OPACITY 100 > CLASS > NAME 'Lakes' > STYLE > COLOR 0 61 245 > END # STYLE > END # CLASS > METADATA > "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" > "wms_title" "Lakes Of The World" > END > END # LAYER > LAYER > NAME "geographic_points" > DATA "./50m_physical/50m_geography_regions_points.shp" > STATUS OFF > TYPE POINT > OPACITY 50 > CLASS > LABEL > COLOR ?0 0 0 > OUTLINECOLOR 255 255 255 > FONT "sans" > TYPE truetype > SIZE 6 > POSITION AUTO > PARTIALS FALSE > END > END # CLASS > METADATA > "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" > "wms_title" "Major Geographic Points" > END > END # LAYER > LAYER > NAME "countries" > DATA "./country2007/cntry07_econ.shp" > STATUS OFF > TYPE POLYGON > CLASS > NAME 'The Countries Of The World' > STYLE > OUTLINECOLOR 0 0 0 > END # STYLE > END # CLASS > METADATA > "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" > "wms_title" "The Countries Of The World" > END > END # LAYER > LAYER > NAME "state_lines_usa" > DATA "./50m_cultural/ne_50m_admin_1_states_provinces_shp.shp" > STATUS OFF > TYPE POLYGON > CLASS > NAME 'States Lines USA' > STYLE > OUTLINECOLOR 0 0 0 > END # STYLE > END # CLASS > METADATA > "wms_title" "States Lines USA" > END > END # LAYER > LAYER > NAME "urban_areas" > DATA "./50m_cultural/ne_50m_urban_areas.shp" > STATUS OFF > TYPE POLYGON > CLASS > NAME 'Urban Areas' > STYLE > OUTLINECOLOR 0 0 0 > END # STYLE > END # CLASS > METADATA > "wms_title" "Urban Areas" > END > END # LAYER > #LAYER > # NAME "populated_places" > # DATA "./50m_cultural/ne_50m_populated_places.shp" > # STATUS OFF > # TYPE POINT > # > # > # METADATA > # "wms_title" "Populated Places" > # END > # > #END # LAYER > > > END # MAP > > Regards, > Dinni. > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From chandrakant.dinni at edurite.com Sun Apr 1 23:10:51 2012 From: chandrakant.dinni at edurite.com (Chandrakant Dinni) Date: Mon, 2 Apr 2012 11:40:51 +0530 Subject: [mapserver-users] MapServer CGI 5.6.6 and MapServer CGI 6.0.2 image quality varies. In-Reply-To: References: Message-ID: Hi, Thanks that resolved the issue. I was requesting the image as png, so added below lines to map file with jpeg substituted for png. Thank you for the quick reply :) Regards, Dinni On Mon, Apr 2, 2012 at 11:11 AM, thomas bonfort wrote: > how are you requesting the image ? > > you can add this to your mapfile: > > outputformat > ?name "aggjpeg" > ?driver "AGG/JPEG" > ?mimetype "image/jpeg" > ?imagemode rgb > end > > > > On Mon, Apr 2, 2012 at 06:47, Chandrakant Dinni > wrote: >> Hi, >> >> The attached images are from same map files (bluemarble imagery from >> http://visibleearth.nasa.gov/view.php?id=57752) . >> >> 1)Improper_Mapserver5.6.6.JPG?the colours are not smooth,the picture >> is pixellated in Mapserver 5.6.6 >> 2) Proper_Mapserver6.0.2.JPG??the colours are smooth in Mapserver 6.0.2. >> >> How can I make the image show properly in 5.6.6, what makes the difference ? >> Tried using untiled images but the result is the same in 5.6.6.There >> could me some mapserver setting or preprocessing to be done on image >> files. >> >> Right now I am doing only this to get the final images. >> gdal_translate -co TILED=YES land_shallow_topo_8192.tif >> land_shallow_topo_8192_TILED.tif >> gdaladdo --config GDAL_CACHEMAX 1500 -r average >> land_shallow_topo_8192_TILED.tif 4 8 16 32 64 128 256 >> >> Also any know any better\more detailed sources for public domain atlas >> images,I am also using http://www.naturalearthdata.com/ as a source of >> data. >> Thanks in advance....I am planning to use Mapserver 5.6.6 because the >> Fusion JavaScript Client is compatible with 5.6.6. > don't know the specifics of fusion, but if it's javascript only I > don't think it wouldn't work with 6.0. > > regards, > thomas > >> >> I am using ms4w for testing ,though final server will be on linux. >> Below is the map file. >> >> MAP >> ? ? NAME "BlueMarble" >> PROJECTION >> # "init=EPSG:4326" >> "proj=latlong" >> END >> ? ? STATUS ON >> ? ? SIZE 10800 5400 >> ? ? EXTENT -180 -90 180 90 >> >> ? ? UNITS DD >> ? ? SHAPEPATH "../NaturalEarth" >> # don't need background colour >> ? ? # IMAGECOLOR 128 128 255 >> >> ? ? # >> ? ? # Start of web interface definition >> ? ? # >> ? ? WEB >> ? ? ? ? IMAGEPATH "/ms4w/tmp/ms_tmp/" >> ? ? ? ? IMAGEURL "/ms_tmp/" >> METADATA >> "wms_title" ? ? ? ? ? "WMS Server" >> "wms_onlineresource" >> "http://172.16.1.126/cgi-bin/mapserv.exe?map=/ms4w/data/mapfiles/bluemarble.map&" >> "wms_extent" ?"-180 -90 180 90" >> "wms_enable_request" ?"*" >> END >> ? ? END # WEB >> >> LAYER >> ? ? ?NAME "NasaBlueMarbleOffline" >> ? ? ?DATA "./bluemarble/land_shallow_topo_8192_TILED.tif" >> STATUS ON >> ? ? ?TYPE RASTER >> ? ? ?PROJECTION >> ? ? ? ?"proj=latlong" >> ? ? ?END >> >> ? ? ?METADATA >> "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" >> ? ? ? ?"wms_title" "Nasa Blue Marble Offline" >> ? ? ?END >> END >> LAYER >> NAME "world_land" >> DATA "./50m_physical/50m_land.shp" >> STATUS OFF >> TYPE POLYGON >> OPACITY 100 >> CLASS >> NAME 'Land Outline' >> STYLE >> OUTLINECOLOR 184 ?138 ?0 >> END # STYLE >> END # CLASS >> METADATA >> "wms_title" "Land Outline" >> END >> END # LAYER >> LAYER >> NAME "world_freshwater_bodies" >> DATA "./50m_physical/50m_rivers_lake_centerlines.shp" >> STATUS OFF >> TYPE LINE >> OPACITY 100 >> CLASS >> NAME 'Fresh Water Bodies' >> STYLE >> OUTLINECOLOR 51 ?102 ?255 >> END # STYLE >> END # CLASS >> METADATA >> "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" >> "wms_title" "Freshwater Bodies Of The World" >> END >> END # LAYER >> LAYER >> NAME "world_lakes" >> DATA "./50m_physical/50m_lakes.shp" >> STATUS OFF >> TYPE POLYGON >> OPACITY 100 >> CLASS >> NAME 'Lakes' >> STYLE >> COLOR 0 61 245 >> END # STYLE >> END # CLASS >> METADATA >> "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" >> "wms_title" "Lakes Of The World" >> END >> END # LAYER >> LAYER >> NAME "geographic_points" >> DATA "./50m_physical/50m_geography_regions_points.shp" >> STATUS OFF >> TYPE POINT >> OPACITY 50 >> CLASS >> LABEL >> COLOR ?0 0 0 >> OUTLINECOLOR 255 255 255 >> FONT "sans" >> TYPE truetype >> SIZE 6 >> POSITION AUTO >> PARTIALS FALSE >> END >> END # CLASS >> METADATA >> "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" >> "wms_title" "Major Geographic Points" >> END >> END # LAYER >> LAYER >> NAME "countries" >> DATA "./country2007/cntry07_econ.shp" >> STATUS OFF >> TYPE POLYGON >> CLASS >> NAME 'The Countries Of The World' >> STYLE >> OUTLINECOLOR 0 0 0 >> END # STYLE >> END # CLASS >> METADATA >> "wms_srs" ? ? ? ? ? ? "EPSG:4269 EPSG:4326" >> "wms_title" "The Countries Of The World" >> END >> END # LAYER >> LAYER >> NAME "state_lines_usa" >> DATA "./50m_cultural/ne_50m_admin_1_states_provinces_shp.shp" >> STATUS OFF >> TYPE POLYGON >> CLASS >> NAME 'States Lines USA' >> STYLE >> OUTLINECOLOR 0 0 0 >> END # STYLE >> END # CLASS >> METADATA >> "wms_title" "States Lines USA" >> END >> END # LAYER >> LAYER >> NAME "urban_areas" >> DATA "./50m_cultural/ne_50m_urban_areas.shp" >> STATUS OFF >> TYPE POLYGON >> CLASS >> NAME 'Urban Areas' >> STYLE >> OUTLINECOLOR 0 0 0 >> END # STYLE >> END # CLASS >> METADATA >> "wms_title" "Urban Areas" >> END >> END # LAYER >> #LAYER >> # NAME "populated_places" >> # DATA "./50m_cultural/ne_50m_populated_places.shp" >> # STATUS OFF >> # TYPE POINT >> # >> # >> # METADATA >> # "wms_title" "Populated Places" >> # END >> # >> #END # LAYER >> >> >> END # MAP >> >> Regards, >> Dinni. >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> From lists at remoteinformation.com.au Sun Apr 1 23:39:51 2012 From: lists at remoteinformation.com.au (Ben Madin) Date: Mon, 2 Apr 2012 14:39:51 +0800 Subject: [mapserver-users] Validation error (but working!) Message-ID: G'day all, I've noticed that when I turn layer (going out as a WMS service) debugging on, I am getting the messages shown below (the layer is rendering as I expected, with only the names for the selected country showing up). As I said, it is working, but what is wrong with my patterns - I suspect other layers with the same validation patterns would be giving the same errors, but I haven't investigated them (as they are working) My confusion is : Either the validation is working (and the log message is wrong), or I am failing to understand how the validation is meant to work, or The validation is failing, but not being respected? any clues cheers Ben Log messages : [Mon Apr 2 14:29:40 2012].960342 runtime substitution - Layer provnames, tag %CCODE%... [Mon Apr 2 14:29:40 2012].960725 msValidateParameter(): Regular expression error. Parameter pattern validation failed. [Mon Apr 2 14:29:40 2012].960759 msValidateParameter(): Regular expression error. Parameter pattern validation failed. [Mon Apr 2 14:29:40 2012].960775 runtime substitution - Layer provnames, tag %YEAR%... [Mon Apr 2 14:29:40 2012].961353 msDrawMap(): rendering using outputformat named AGG (AGG/PNG). [Mon Apr 2 14:29:40 2012].993291 msPostGISLayerIsOpen called. The layer has a validation pattern and defaults set: METADATA "wms_title" "provnames" "wms_srs" "EPSG:4326" "wms_group_title" "Administrative" "default_ccode" "AUS" "default_year" "2010" END VALIDATION 'ccode' '[A-Z]{3}' 'year' '20[0-1][0-9]' END and the query is : DATA "geom from ( SELECT recordid as gid, geom, name as pname FROM geolayer WHERE validitystarts <= '%YEAR%' AND (validityends >= '%YEAR%' OR validityends IS NULL) AND country LIKE '%CCODE%' ) AS foo USING UNIQUE gid USING SRID=4326" TYPE ANNOTATION labelmaxscaledenom 5000000 LABELITEM pname CLASS LABEL COLOR 150 150 250 OUTLINECOLOR 255 255 255 FONT "lucida" TYPE truetype SIZE 9 POSITION AUTO PARTIALS FALSE END END and the version is : MapServer version 6.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=CAIRO SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE From thomas.bonfort at gmail.com Mon Apr 2 01:55:07 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Mon, 2 Apr 2012 10:55:07 +0200 Subject: [mapserver-users] Validation error (but working!) In-Reply-To: References: Message-ID: Ben, if the validation fails, the default_xxx parameter is used instead, which is why no further errors are reported. what are you sending in your url for CCODE ? -- thomas On Mon, Apr 2, 2012 at 08:39, Ben Madin wrote: > G'day all, > > I've noticed that when I turn layer (going out as a WMS service) debugging on, I am getting the messages shown below (the layer is rendering as I expected, with only the names for the selected country showing up). > > As I said, it is working, but what is wrong with my patterns - I suspect other layers with the same validation patterns would be giving the same errors, but I haven't investigated them (as they are working) > > My confusion is : > > Either the validation is working (and the log message is wrong), or > > I am failing to understand how the validation is meant to work, or > > The validation is failing, but not being respected? > > any clues > > cheers > > Ben > > > > Log messages : > > [Mon Apr ?2 14:29:40 2012].960342 ? runtime substitution - Layer provnames, tag %CCODE%... > [Mon Apr ?2 14:29:40 2012].960725 msValidateParameter(): Regular expression error. Parameter pattern validation failed. > [Mon Apr ?2 14:29:40 2012].960759 msValidateParameter(): Regular expression error. Parameter pattern validation failed. > [Mon Apr ?2 14:29:40 2012].960775 ? runtime substitution - Layer provnames, tag %YEAR%... > [Mon Apr ?2 14:29:40 2012].961353 msDrawMap(): rendering using outputformat named AGG (AGG/PNG). > [Mon Apr ?2 14:29:40 2012].993291 msPostGISLayerIsOpen called. > > The layer has a validation pattern and defaults set: > > ? ? ? ? ? ? ? ?METADATA > ? ? ? ? ? ? ? ? ? ? ? ?"wms_title" ? ? ? ? ? ? "provnames" > ? ? ? ? ? ? ? ? ? ? ? ?"wms_srs" ? ? ? ? ? ? ? "EPSG:4326" > ? ? ? ? ? ? ? ? ? ? ? ?"wms_group_title" "Administrative" > ? ? ? ? ? ? ? ? ? ? ? ?"default_ccode" ? ? ? ? "AUS" > ? ? ? ? ? ? ? ? ? ? ? ?"default_year" ? ? ? ? ?"2010" > ? ? ? ? ? ? ? ?END > ? ? ? ? ? ? ? ?VALIDATION > ? ? ? ? ? ? ? ? ? ? ? ?'ccode' '[A-Z]{3}' > ? ? ? ? ? ? ? ? ? ? ? ?'year' '20[0-1][0-9]' > ? ? ? ? ? ? ? ?END > > and the query is : > > ? ? ? ?DATA ? ?"geom from ( > ? ? ? ? ? ? ? ?SELECT ?recordid as gid, geom, name as pname > ? ? ? ? ? ? ? ?FROM ? ?geolayer > ? ? ? ? ? ? ? ?WHERE validitystarts <= '%YEAR%' > ? ? ? ? ? ? ? ? ? ? ? ?AND (validityends >= '%YEAR%' OR validityends IS NULL) > ? ? ? ? ? ? ? ? ? ? ? ?AND country LIKE '%CCODE%' > ? ? ? ? ? ? ? ?) AS foo USING UNIQUE gid USING SRID=4326" > ? ? ? ?TYPE ? ?ANNOTATION > ? ? ? ?labelmaxscaledenom 5000000 > ? ? ? ?LABELITEM pname > ? ? ? ?CLASS > ? ? ? ? ? ? ? ? ? ? ? ?LABEL > ? ? ? ? ? ? ? ? ? ? ? ? ?COLOR ?150 150 250 > ? ? ? ? ? ? ? ? ? ? ? ? ?OUTLINECOLOR 255 255 255 > ? ? ? ? ? ? ? ? ? ? ? ? ?FONT "lucida" > ? ? ? ? ? ? ? ? ? ? ? ? ?TYPE truetype > ? ? ? ? ? ? ? ? ? ? ? ? ?SIZE 9 > ? ? ? ? ? ? ? ? ? ? ? ? ?POSITION AUTO > ? ? ? ? ? ? ? ? ? ? ? ? ?PARTIALS FALSE > ? ? ? ? ? ? ? ? ? END > ? ? ? ? ? ? ? ?END > > > and the version is : > > MapServer version 6.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=CAIRO SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From lists at remoteinformation.com.au Mon Apr 2 06:19:01 2012 From: lists at remoteinformation.com.au (Ben Madin) Date: Mon, 2 Apr 2012 21:19:01 +0800 Subject: [mapserver-users] Validation error (but working!) In-Reply-To: References: Message-ID: <90120D60-2480-4205-9071-85C656D0AF12@remoteinformation.com.au> Thanks Thomas, On 02/04/2012, at 4:55 PM, thomas bonfort wrote: > if the validation fails, the default_xxx parameter is used instead, > which is why no further errors are reported. > > what are you sending in your url for CCODE ? I should have included it - sorry ! The url normally looks like : maps/index.php?page=details&ccode=EST&mapcode=156&year=2005&submit=submit 'tis unfortunately a local system, and the size of the data files somewhat limits my opportunity to put an example up somewhere. cheers Ben > On Mon, Apr 2, 2012 at 08:39, Ben Madin wrote: >> G'day all, >> >> I've noticed that when I turn layer (going out as a WMS service) debugging on, I am getting the messages shown below (the layer is rendering as I expected, with only the names for the selected country showing up). >> >> As I said, it is working, but what is wrong with my patterns - I suspect other layers with the same validation patterns would be giving the same errors, but I haven't investigated them (as they are working) >> >> My confusion is : >> >> Either the validation is working (and the log message is wrong), or >> >> I am failing to understand how the validation is meant to work, or >> >> The validation is failing, but not being respected? >> >> any clues >> >> cheers >> >> Ben >> >> >> >> Log messages : >> >> [Mon Apr 2 14:29:40 2012].960342 runtime substitution - Layer provnames, tag %CCODE%... >> [Mon Apr 2 14:29:40 2012].960725 msValidateParameter(): Regular expression error. Parameter pattern validation failed. >> [Mon Apr 2 14:29:40 2012].960759 msValidateParameter(): Regular expression error. Parameter pattern validation failed. >> [Mon Apr 2 14:29:40 2012].960775 runtime substitution - Layer provnames, tag %YEAR%... >> [Mon Apr 2 14:29:40 2012].961353 msDrawMap(): rendering using outputformat named AGG (AGG/PNG). >> [Mon Apr 2 14:29:40 2012].993291 msPostGISLayerIsOpen called. >> >> The layer has a validation pattern and defaults set: >> >> METADATA >> "wms_title" "provnames" >> "wms_srs" "EPSG:4326" >> "wms_group_title" "Administrative" >> "default_ccode" "AUS" >> "default_year" "2010" >> END >> VALIDATION >> 'ccode' '[A-Z]{3}' >> 'year' '20[0-1][0-9]' >> END >> >> and the query is : >> >> DATA "geom from ( >> SELECT recordid as gid, geom, name as pname >> FROM geolayer >> WHERE validitystarts <= '%YEAR%' >> AND (validityends >= '%YEAR%' OR validityends IS NULL) >> AND country LIKE '%CCODE%' >> ) AS foo USING UNIQUE gid USING SRID=4326" >> TYPE ANNOTATION >> labelmaxscaledenom 5000000 >> LABELITEM pname >> CLASS >> LABEL >> COLOR 150 150 250 >> OUTLINECOLOR 255 255 255 >> FONT "lucida" >> TYPE truetype >> SIZE 9 >> POSITION AUTO >> PARTIALS FALSE >> END >> END >> >> >> and the version is : >> >> MapServer version 6.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=CAIRO SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users From Jukka.Rahkonen at mmmtike.fi Mon Apr 2 07:46:35 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Mon, 2 Apr 2012 14:46:35 +0000 Subject: [mapserver-users] Validation error (but working!) In-Reply-To: <90120D60-2480-4205-9071-85C656D0AF12@remoteinformation.com.au> References: <90120D60-2480-4205-9071-85C656D0AF12@remoteinformation.com.au> Message-ID: <84446DEF76453C439E9E97E438E13A631488A0@suutari.haapa.mmm.fi> Hi, Have a try by using either upper case or lower case everywhere, it may help. -Jukka Rahkonen- Ben Madin wrote: > > Thanks Thomas, > > On 02/04/2012, at 4:55 PM, thomas bonfort wrote: > > > if the validation fails, the default_xxx parameter is used instead, > > which is why no further errors are reported. > > > > what are you sending in your url for CCODE ? > > I should have included it - sorry ! The url normally looks like : > > maps/index.php?page=details&ccode=EST&mapcode=156&year=2005&su bmit=submit > > 'tis unfortunately a local system, and the size of the data > files somewhat limits my opportunity to put an example up somewhere. > > cheers > > Ben > > > > > On Mon, Apr 2, 2012 at 08:39, Ben Madin > wrote: > >> G'day all, > >> > >> I've noticed that when I turn layer (going out as a WMS > service) debugging on, I am getting the messages shown below > (the layer is rendering as I expected, with only the names > for the selected country showing up). > >> > >> As I said, it is working, but what is wrong with my > patterns - I suspect other layers with the same validation > patterns would be giving the same errors, but I haven't > investigated them (as they are working) > >> > >> My confusion is : > >> > >> Either the validation is working (and the log message is wrong), or > >> > >> I am failing to understand how the validation is meant to work, or > >> > >> The validation is failing, but not being respected... > >> > >> any clues > >> > >> cheers > >> > >> Ben > >> > >> > >> > >> Log messages : > >> > >> [Mon Apr 2 14:29:40 2012].960342 runtime substitution - > Layer provnames, tag %CCODE%... > >> [Mon Apr 2 14:29:40 2012].960725 msValidateParameter(): > Regular expression error. Parameter pattern validation failed. > >> [Mon Apr 2 14:29:40 2012].960759 msValidateParameter(): > Regular expression error. Parameter pattern validation failed. > >> [Mon Apr 2 14:29:40 2012].960775 runtime substitution - > Layer provnames, tag %YEAR%... > >> [Mon Apr 2 14:29:40 2012].961353 msDrawMap(): rendering > using outputformat named AGG (AGG/PNG). > >> [Mon Apr 2 14:29:40 2012].993291 msPostGISLayerIsOpen called. > >> > >> The layer has a validation pattern and defaults set: > >> > >> METADATA > >> "wms_title" "provnames" > >> "wms_srs" "EPSG:4326" > >> "wms_group_title" "Administrative" > >> "default_ccode" "AUS" > >> "default_year" "2010" > >> END > >> VALIDATION > >> 'ccode' '[A-Z]{3}' > >> 'year' '20[0-1][0-9]' > >> END > >> > >> and the query is : > >> > >> DATA "geom from ( > >> SELECT recordid as gid, geom, name as pname > >> FROM geolayer > >> WHERE validitystarts <= '%YEAR%' > >> AND (validityends >= '%YEAR%' OR > validityends IS NULL) > >> AND country LIKE '%CCODE%' > >> ) AS foo USING UNIQUE gid USING SRID=4326" > >> TYPE ANNOTATION > >> labelmaxscaledenom 5000000 > >> LABELITEM pname > >> CLASS > >> LABEL > >> COLOR 150 150 250 > >> OUTLINECOLOR 255 255 255 > >> FONT "lucida" > >> TYPE truetype > >> SIZE 9 > >> POSITION AUTO > >> PARTIALS FALSE > >> END > >> END > >> > >> > >> and the version is : > >> > >> MapServer version 6.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG > OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=CAIRO > SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER > SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT > SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS > SUPPORTS=GEOS INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE > >> > >> _______________________________________________ > >> mapserver-users mailing list > >> mapserver-users at lists.osgeo.org > >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From stefanie.senn at wheregroup.com Tue Apr 3 01:37:26 2012 From: stefanie.senn at wheregroup.com (Stefanie Senn) Date: Tue, 03 Apr 2012 10:37:26 +0200 Subject: [mapserver-users] GetFeatureInfo Response from shapefile is wrong, also the Labeling Message-ID: <4F7AB6C6.9050000@wheregroup.com> Hi all, I have an problem with my GetFeatureInfo and also with the Labeling from shapefiles data. I get the wrong parameters back. For example: If I make a gfi at my Layer "Contour Line" or have a look at the labeling I got the value "_4.4500000000e+002 back_". But normaly, if I open my shapfile "Contour Line" at QGIS or something else and make a querie I got the normal value"_430_" from the attribute column. The strange thing is not all parameters get wrong back after a request. Did anyone knows what can be the problem and now how to solve it? Thanks, Stefanie Senn -- ******************************************** FOSS Academy Sommerschule 2012 GDI in 5 Tagen! http://www.foss-academy.eu/sommerschule ******************************************** --------------------------------------- Stefanie Senn WhereGroup GmbH& Co. KG Eifelstra?e 7 53119 Bonn Germany Fon: +49 (0)228 / 90 90 38 - 34 Fax: +49 (0)228 / 90 90 38 - 11 mailto:stefanie.senn at wheregroup.com info at wheregroup.com www.wheregroup.com Folgen Sie der WhereGroup auf twitter: http://twitter.com/WhereGroup_com Amtsgericht Bonn, HRA 6788 ------------------------------- Komplement?rin: WhereGroup Verwaltungs GmbH vertreten durch: Olaf Knopp, Peter Stamm --------------------------------------- -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Tue Apr 3 07:54:16 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Tue, 03 Apr 2012 09:54:16 -0500 Subject: [mapserver-users] Anyone used MapServer to draw (things other than maps) with? Message-ID: <4F7AC8C8020000A800034D30@heckle> All, I'm needing to draw some simple, but longish charts showing a GPS timeline. I'm thinking about trying to set up MapServer to generate them dynamically. In the past I would have went to PGPLOT for this type of thing (It's what I used for mapping before finding MapServer), And I see that it's installed in Ubuntu now by default. So, my question, is this worth anything to anyone else? has anyone done this already, got any pointers? The data is all in POSTGIS, so I have a fair level of flexibility with formatting the data for MapServer use. I could for example format my data in such a way as to fool mapserver into thinking it's some sort of map projection for display, etc. I assume all should work well with straight Cartesian Coordinates. Thanks bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From jacksonje at gmail.com Tue Apr 3 07:57:38 2012 From: jacksonje at gmail.com (Jason Jackson) Date: Tue, 3 Apr 2012 09:57:38 -0500 Subject: [mapserver-users] How to disable repeated labels Message-ID: I would like to disable the repeating of labels along roads in a mapserver 5.6 based map. However, whether or not I use the REPEATDISTANCE setting for the LABEL and irregardless of its setting, I get too many repeated labels. Is there anything I can do to prevent it repeating the labels? Thank you, Jason From woodbri at swoodbridge.com Tue Apr 3 07:59:11 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Tue, 03 Apr 2012 10:59:11 -0400 Subject: [mapserver-users] How to disable repeated labels In-Reply-To: References: Message-ID: <4F7B103F.8000301@swoodbridge.com> On 4/3/2012 10:57 AM, Jason Jackson wrote: > I would like to disable the repeating of labels along roads in a > mapserver 5.6 based map. However, whether or not I use the > REPEATDISTANCE setting for the LABEL and irregardless of its setting, > I get too many repeated labels. Is there anything I can do to prevent > it repeating the labels? REPEATDISTANCE is to force labels to repeat. You want to set MINDISTANCE to a value greate than you image width or height. -Steve W From ian.walberg at airborne.aero Tue Apr 3 08:04:10 2012 From: ian.walberg at airborne.aero (Ian Walberg) Date: Tue, 3 Apr 2012 11:04:10 -0400 Subject: [mapserver-users] Anyone used MapServer to draw (things other thanmaps) with? In-Reply-To: <4F7AC8C8020000A800034D30@heckle> References: <4F7AC8C8020000A800034D30@heckle> Message-ID: Bob, We draw some data tables with maps as backgrounds by setting the transform off and then using simple x y locations and everything works very well. Regards Ian From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Tuesday, April 03, 2012 7:54 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Anyone used MapServer to draw (things other thanmaps) with? All, I'm needing to draw some simple, but longish charts showing a GPS timeline. I'm thinking about trying to set up MapServer to generate them dynamically. In the past I would have went to PGPLOT for this type of thing (It's what I used for mapping before finding MapServer), And I see that it's installed in Ubuntu now by default. So, my question, is this worth anything to anyone else? has anyone done this already, got any pointers? The data is all in POSTGIS, so I have a fair level of flexibility with formatting the data for MapServer use. I could for example format my data in such a way as to fool mapserver into thinking it's some sort of map projection for display, etc. I assume all should work well with straight Cartesian Coordinates. Thanks bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at state.mn.us Tue Apr 3 08:07:07 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Tue, 3 Apr 2012 15:07:07 +0000 Subject: [mapserver-users] Anyone used MapServer to draw (things other than maps) with? In-Reply-To: <4F7AC8C8020000A800034D30@heckle> References: <4F7AC8C8020000A800034D30@heckle> Message-ID: I've done a bit of this with river cross sections but IMHO there are simply better tools out there. Personally I like matplotlib although the learning curve is a little steep. You can do a lot with not much code. Steve ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] on behalf of Bob Basques [Bob.Basques at ci.stpaul.mn.us] Sent: Tuesday, April 03, 2012 9:54 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Anyone used MapServer to draw (things other than maps) with? All, I'm needing to draw some simple, but longish charts showing a GPS timeline. I'm thinking about trying to set up MapServer to generate them dynamically. In the past I would have went to PGPLOT for this type of thing (It's what I used for mapping before finding MapServer), And I see that it's installed in Ubuntu now by default. So, my question, is this worth anything to anyone else? has anyone done this already, got any pointers? The data is all in POSTGIS, so I have a fair level of flexibility with formatting the data for MapServer use. I could for example format my data in such a way as to fool mapserver into thinking it's some sort of map projection for display, etc. I assume all should work well with straight Cartesian Coordinates. Thanks bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From simoschr at uni-osnabrueck.de Wed Apr 4 04:08:44 2012 From: simoschr at uni-osnabrueck.de (=?ISO-8859-15?Q?Simon_Schr=F6der?=) Date: Wed, 04 Apr 2012 13:08:44 +0200 Subject: [mapserver-users] CITE Test WMS 1.3.0 - Test GetFeatureInfo query layers not queryable Message-ID: <4F7C2BBC.6010604@uni-osnabrueck.de> Dear MapServer Users, I'm trying to get through the online CITE compliance test with WMS 1.3.0 on MS 6.0.2 using the CITE test dataset (R1) from here: http://cite.opengeospatial.org/teamengine/ I already have the WMS 1.1.1 successfully tested. And I also figured out the extent problem with the Bridges.shp layer in WMS 1.3.0 and "corrected" it. At the moment I pass 199 tests, so there is only one test missing. It's in the GetFeatureInfo section: Test getfeatureinfo:query_layers-not-queryable Assertion: When GetFeatureInfo is requested on a Layer that is not queryable, then the server issues a Service Exception (code=LayerNotQueryable). Here is the complete test result: www.carlosx.de/ogc/getfeatureinfo_not.htm When I make the request manually, i get these feature infos (which I shouldn't get): GetFeatureInfo results: Layer 'cite:BasicPolygons' Feature 0: ID = '' Layer 'cite:Forests' Feature 0: FID = '109' NAME = 'Green Forest' Here is the complete mapfile: www.carlosx.de/ogc/wms_test.map At the moment I haven't got any clue where the problem is. Already getting a little tired of testing the last days. I would appreciate it, if anyone can help me with this issue. Thx a lot! Greetings from Bremen. Simon Schr?der -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Wed Apr 4 13:23:24 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Wed, 4 Apr 2012 20:23:24 +0000 Subject: [mapserver-users] Using 2 attributes in 1 class Message-ID: Hi All, I am working on a project and I want to demonstrate a gold mine which is producing mine by using 2 expressions like below. I just want to use 2 attribute from same layer.I don't know if I am in right way. How can I make it? Is it possible? Can someone share his/her ideas about the problem? Thanks Ozz CLASSITEM 'P_COMMOD' CLASSITEM 'STATUS' HEADER "MDI_2011_GOLD_header.html" FOOTER "MDI_2011_GOLD_footer.html" TOLERANCE 5 TOLERANCEUNITS PIXELS CLASS NAME "GOLD" EXPRESSION ("GOLD"="PRODUCING MINE") -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Wed Apr 4 13:38:26 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Wed, 04 Apr 2012 16:38:26 -0400 Subject: [mapserver-users] Using 2 attributes in 1 class In-Reply-To: References: Message-ID: <4F7CB142.3010508@swoodbridge.com> On 4/4/2012 4:23 PM, ?zg?r Arslan wrote: > Hi All, > > I am working on a project and I want to demonstrate a gold mine which is > producing mine by using 2 expressions like below. I just want to use 2 > attribute from same layer.I don't know if I am in right way. How can I > make it? Is it possible? Can someone share his/her ideas about the problem? > > Thanks > > Ozz > > > CLASSITEM 'P_COMMOD' > CLASSITEM 'STATUS' > > HEADER "MDI_2011_GOLD_header.html" > FOOTER "MDI_2011_GOLD_footer.html" > > TOLERANCE 5 > TOLERANCEUNITS PIXELS > > > CLASS > NAME "GOLD" > EXPRESSION ("GOLD"="PRODUCING MINE") EXPRESSION ('[P_COMMOD]' = 'GOLD' && '[STATUS]' = 'PRODUCING MINE') and you do not need any CLASSITEM in this case. -Steve W From ozgurarslan81 at hotmail.com Thu Apr 5 19:38:30 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Fri, 6 Apr 2012 02:38:30 +0000 Subject: [mapserver-users] HELLLPPP!!!! Message-ID: Hi All I have a map file called QGISMap.map I am trying to make it appear in a frame that created by using open layers. But when I run the page it only shows a empty frame. Why it doesn't show the map? Can someone help me please? Codes are below: OpenLayers Tutorial - Basic Map Setup

OpenLayers Tutorial - Basic Map Setup

-------------- next part -------------- An HTML attachment was scrubbed... URL: From pcreso at pcreso.com Thu Apr 5 20:04:01 2012 From: pcreso at pcreso.com (pcreso at pcreso.com) Date: Thu, 5 Apr 2012 20:04:01 -0700 (PDT) Subject: [mapserver-users] HELLLPPP!!!! In-Reply-To: Message-ID: <1333681441.48690.YahooMailClassic@web160706.mail.bf1.yahoo.com> There are many places there could be a problem I suggest you start by entering the URL for the capabilities document into your browser & make sure that is actually working. http://localhost/cgi-bin/mapserv.exe?map=C:/wwwroot/QGISMap/QGISMap.map&service=WMS&request=getcapabilities&version=1.3.0 Depending on what this says you can probably work through the problem. It should list the map layer you are asking for. Brent Wood --- On Fri, 4/6/12, ?zg?r Arslan wrote: From: ?zg?r Arslan Subject: [mapserver-users] HELLLPPP!!!! To: mapserver-users at lists.osgeo.org Date: Friday, April 6, 2012, 2:38 PM Hi All I have a map file called QGISMap.map I am trying to make it appear in a frame that created by using open layers. But when I run the page it only shows a empty frame. Why it doesn't show the map? Can someone help me please? Codes are below: ? ? ? ??? OpenLayers Tutorial - Basic Map Setup ??? ??? ? ??? ? ? ???

OpenLayers Tutorial - Basic Map Setup

???
? -----Inline Attachment Follows----- _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From Jukka.Rahkonen at mmmtike.fi Thu Apr 5 21:01:24 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Fri, 6 Apr 2012 04:01:24 +0000 Subject: [mapserver-users] HELLLPPP!!!! In-Reply-To: References: Message-ID: <84446DEF76453C439E9E97E438E13A6314919E@suutari.haapa.mmm.fi> Hi, First thing is probably that QGis does not make valid mapfiles for Mapserver version 6.0. Start with simple hand written mapfiles following the examples with Mapserver documentation. And do not start testing the mapfiles with OpenLayers. Use shp2img and browser with hand written WMS GetMap requests first so the control is in your hands. -Jukka Rahkonen- ________________________________ L?hett?j?: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] k?ytt?j?n ?zg?r Arslan [ozgurarslan81 at hotmail.com] puolesta L?hetetty: 6. huhtikuuta 2012 5:38 Vastaanottaja: mapserver-users at lists.osgeo.org Aihe: [mapserver-users] HELLLPPP!!!! Hi All I have a map file called QGISMap.map I am trying to make it appear in a frame that created by using open layers. But when I run the page it only shows a empty frame. Why it doesn't show the map? Can someone help me please? Codes are below: OpenLayers Tutorial - Basic Map Setup

OpenLayers Tutorial - Basic Map Setup

From MarkVolz at co.lyon.mn.us Fri Apr 6 08:07:04 2012 From: MarkVolz at co.lyon.mn.us (Mark Volz) Date: Fri, 6 Apr 2012 15:07:04 +0000 Subject: [mapserver-users] placement of labels from two different polygons that have the same feature shape Message-ID: <36CA828A36E29F45B7CF0A1766E5DFA30F72FB@swmail01.r8nssis.local> Hello, I would like to label both parcel polygons, and lot polygons on my map. Unfortunately, if the parcel and the lot have the exact same boundary, only the parcel is labeled. Does anyone have any ideas or map files on how I could label both parcel polygons and lot polygons? Am I missing a keyword that when the parcel is labeled at the center of the bounding box, a secondary label for the lots could be placed within the open area of the boundary box? I asked this question last year, at the time one person suggested that I could convert my data into points, which has more labeling positions. Unfortunately, I would prefer not to convert my data into points for labeling as I would like to take advantage MINFEATURESIZE AUTO which only works with polygons. P.S. I found that the wrap keyword works so It is possible to label both parcels and lots. However, since extra lines are added the label might fall on top of the wrong lot if I zoom out too far. Thank you Mark Volz GIS Specialist -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Fri Apr 6 08:35:09 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Fri, 06 Apr 2012 11:35:09 -0400 Subject: [mapserver-users] placement of labels from two different polygons that have the same feature shape In-Reply-To: <36CA828A36E29F45B7CF0A1766E5DFA30F72FB@swmail01.r8nssis.local> References: <36CA828A36E29F45B7CF0A1766E5DFA30F72FB@swmail01.r8nssis.local> Message-ID: <4F7F0D2D.1090703@swoodbridge.com> On 4/6/2012 11:07 AM, Mark Volz wrote: > Hello, > I would like to label both parcel polygons, and lot polygons on my map. > Unfortunately, if the parcel and the lot have the exact same boundary, > only the parcel is labeled. Does anyone have any ideas or map files on > how I could label both parcel polygons and lot polygons? Am I missing a > keyword that when the parcel is labeled at the center of the bounding > box, a secondary label for the lots could be placed within the open area > of the boundary box? > I asked this question last year, at the time one person suggested that I > could convert my data into points, which has more labeling positions. > Unfortunately, I would prefer not to convert my data into points for > labeling as I would like to take advantage MINFEATURESIZE AUTO which > only works with polygons. > P.S. I found that the wrap keyword works so It is possible to label both > parcels and lots. However, since extra lines are added the label might > fall on top of the wrong lot if I zoom out too far. > Thank you > Mark Volz > GIS Specialist Mark, The easiest way to do this is to do something like set the possition of one to be UC and the other to be LC. you can also push them farther apart by using OFFSET to move the upper one higher and the lower one lower. You might also try POSITION AUTO, but if you use BUFFER this will not help. -Steve W From MarkVolz at co.lyon.mn.us Fri Apr 6 11:12:49 2012 From: MarkVolz at co.lyon.mn.us (Mark Volz) Date: Fri, 6 Apr 2012 18:12:49 +0000 Subject: [mapserver-users] placement of labels from two different In-Reply-To: <20120406160016.956DDE00D63@lists.osgeo.org> References: <20120406160016.956DDE00D63@lists.osgeo.org> Message-ID: <36CA828A36E29F45B7CF0A1766E5DFA30F7390@swmail01.r8nssis.local> Steve, Thank you for your comments. I should have mentioned that I am using multi-line labels so using position did not move the label over quite enough. However, I was able to get the label to work by using offset which allows me to get the label in closer than when I was using wrap to create empty lines to move the label up. I wish there were some better options for label placement such as fit a second label inside the largest area of a polygon between current labels and the polygon boundary. This way we could force secondary labels to fit within the parcel. Second, it would also be nice if we have a choice to make sure that the labels fit within the bbox, or within the polygon boundary. That way we could make sure that labels fit within the polygon for illregular shaped parcels such as a soils layer. But of course those are unfunded thoughts. Mark Volz GIS Specialist -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of mapserver-users-request at lists.osgeo.org Sent: Friday, April 06, 2012 11:00 AM To: mapserver-users at lists.osgeo.org Subject: mapserver-users Digest, Vol 51, Issue 6 Message: 5 Date: Fri, 06 Apr 2012 11:35:09 -0400 From: Stephen Woodbridge Subject: Re: [mapserver-users] placement of labels from two different polygons that have the same feature shape To: mapserver-users at lists.osgeo.org Message-ID: <4F7F0D2D.1090703 at swoodbridge.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed On 4/6/2012 11:07 AM, Mark Volz wrote: > Hello, > I would like to label both parcel polygons, and lot polygons on my map. > Unfortunately, if the parcel and the lot have the exact same boundary, > only the parcel is labeled. Does anyone have any ideas or map files on > how I could label both parcel polygons and lot polygons? Am I missing > a keyword that when the parcel is labeled at the center of the > bounding box, a secondary label for the lots could be placed within > the open area of the boundary box? > I asked this question last year, at the time one person suggested that > I could convert my data into points, which has more labeling positions. > Unfortunately, I would prefer not to convert my data into points for > labeling as I would like to take advantage MINFEATURESIZE AUTO which > only works with polygons. > P.S. I found that the wrap keyword works so It is possible to label > both parcels and lots. However, since extra lines are added the label > might fall on top of the wrong lot if I zoom out too far. > Thank you > Mark Volz > GIS Specialist Mark, The easiest way to do this is to do something like set the possition of one to be UC and the other to be LC. you can also push them farther apart by using OFFSET to move the upper one higher and the lower one lower. You might also try POSITION AUTO, but if you use BUFFER this will not help. -Steve W ------------------------------ _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users End of mapserver-users Digest, Vol 51, Issue 6 ********************************************** From ozugo at yahoo.com Fri Apr 6 12:59:46 2012 From: ozugo at yahoo.com (Erica) Date: Fri, 6 Apr 2012 12:59:46 -0700 (PDT) Subject: [mapserver-users] Help installing mapserver 4.10.7 Message-ID: <1333742386.26492.YahooMailNeo@web162001.mail.bf1.yahoo.com> I'm attempting to install mapserver 4.10.7 on RHEL 5.6 (kernel?2.6.18-238.35.1.el5). Configure works successfully, but I get the following error when running make: : -Pmsyy -i -omaplexer.c maplexer.l gcc -c -O2 -fPIC -Wall -DHAVE_VSNPRINTF -DNEED_STRLCAT -DUSE_EPPL -DUSE_JPEG -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS -DUSE_ICONV -DUSE_ZLIB -I/usr/include maplexer.c -o maplexer.o gcc: maplexer.c: No such file or directory gcc: no input files make: *** [maplexer.o] Error 1 maplexer.c does not appear to exist either in the tarball or in the branches for 4.10.7. maplexer.o is the only file present. Has anybody encountered this before? What's the workaround? Thanks. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Fri Apr 6 13:17:07 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Fri, 6 Apr 2012 20:17:07 +0000 Subject: [mapserver-users] Help! Message-ID: Hi All, I am new in open layers and I am trying to demonstrate my mapfile with Open layers. Can some one helm me about this please? Code lines are below: OpenLayers Example
# Map file created from QGIS project file # Edit this file to customize for your map interface # (Created with PyQgis MapServer Export plugin) MAP NAME "QGIS-MAP" # Map image size SIZE 500 500 UNITS meters STATUS ON EXTENT -2400000 -900000 3100000 4000000 FONTSET "/wwwroot/fonts/fontset.txt" SYMBOLSET '../symbols/symbols.sty' PROJECTION "proj=lcc" "ellps=GRS80" "lat_0=49" "lon_0=-95" "lat_1=49" "lat_2=77" "datum=NAD83" "units=m" "no_defs <>" END SYMBOL NAME "S3" TYPE pixmap IMAGE '/wwwroot/symbols/S3.png' END # SYMBOL # Background color for the map canvas -- change as desired IMAGECOLOR 0 0 255 IMAGEQUALITY 95 IMAGETYPE png CONFIG "CGI_CONTEXT_URL" "1" OUTPUTFORMAT NAME agg DRIVER AGG/PNG IMAGEMODE RGB END QUERYMAP STATUS ON SIZE 500 500 # sets the map to be queryable STYLE HILITE # the selected object is highligthed COLOR 0 255 0 END # End for QueryMap SCALEBAR STATUS EMBED UNITS KILOMETERS INTERVALS 3 TRANSPARENT TRUE OUTLINECOLOR 0 0 0 END # End for scalebar # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/ms4w/tmp/ms_tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/ms_tmp/' HEADER "header.html" FOOTER "footer.html" EMPTY "/maps/QGISMap/blank.html" # WMS server settings METADATA 'ows_title' 'QGIS-MAP' 'ows_onlineresource' 'localhost/cgi-bin/mapserv.exe?map=C:/wwwroot/QGISMap/QGISMap.map' 'ows_srs' 'EPSG:4326' END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation TEMPLATE 'global.html' END LAYER NAME 'province_dd' TYPE POLYGON DUMP false CONNECTION "http://localhost/cgi-bin/wms?" CONNECTIONTYPE WMS EXTENT -148.317097 42.348600 -55.567680 86.032387 DATA '../../../wwwroot/Data/province_dd.shp' METADATA 'wms_onlineresource' 'http://localhost/cgi-bin/mapserv.exe?map=wms.map&' "wms_srs" "EPSG:4326" "wms_name" "province_dd" "wms_server_version" "1.1.1" "wms_format" "image/gif" #'ows_title' 'province_dd' END STATUS ON TRANSPARENCY 100 PROJECTION 'proj=longlat' 'datum=WGS84' 'no_defs' END LABELITEM 'NAME_ENG' CLASSITEM 'NAME_ENG' CLASS NAME "Alberta" EXPRESSION "Alberta" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 130 9 169 END END CLASS NAME "British Columbia" EXPRESSION "British Columbia" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 62 106 166 END END CLASS NAME "Manitoba" EXPRESSION "Manitoba" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 176 232 23 END END CLASS NAME "New Brunswick" EXPRESSION "New Brunswick" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 248 188 159 END END CLASS NAME "Newfoundland" EXPRESSION "Newfoundland" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 172 33 56 END END CLASS NAME "Northwest Territories" EXPRESSION "Northwest Territories" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 123 03 213 END END CLASS NAME "Nova Scotia" EXPRESSION "Nova Scotia" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 187 66 185 END END CLASS NAME "Nunavut" EXPRESSION "Nunavut" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 171 222 109 END END CLASS NAME "Ontario" EXPRESSION "Ontario" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 250 20 201 END END CLASS NAME "Prince Edward Island" EXPRESSION "Prince Edward Island" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 69 153 254 END END CLASS NAME "Quebec" EXPRESSION "Quebec" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 6 170 235 END END CLASS NAME "Saskatchewan" EXPRESSION "Saskatchewan" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 251 167 144 END END CLASS NAME "Yukon Territory" EXPRESSION "Yukon Territory" STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 26 34 69 END END END LAYER NAME province_labels TYPE ANNOTATION STATUS ON DATA '../../../wwwroot/Data/province_dd.shp' LABELITEM 'NAME_ENG' CLASS LABEL TYPE truetype FONT "calibri" SIZE 9 COLOR 255 255 255 OUTLINECOLOR 0 0 0 POSITION CC MINFEATURESIZE 100 END # End for label END # end for class PROJECTION "proj=latlong" "ellps=WGS84" END # End for projection END # End for layer LAYER NAME 'mjrroads' TYPE LINE DUMP false EXTENT -148.317097 42.348600 -55.567680 86.032387 DATA '../../../wwwroot/Data/mjrroads.shp' METADATA 'ows_title' 'mjrroads' END STATUS ON TRANSPARENCY 100 PROJECTION 'proj=longlat' 'datum=WGS84' 'no_defs' END CLASSITEM 'TYPE' HEADER "mjrroads_header.html" FOOTER "mjrroads_footer.html" TOLERANCE 5 TOLERANCEUNITS PIXELS CLASS NAME "Primary Highway" EXPRESSION "Primary Highway" MAXSCALE 2500000 TEMPLATE "mjrroads_query.html" STYLE WIDTH 1 COLOR 0 0 0 END END CLASS TEMPLATE "mjrroads_query.html" NAME "Expressway" EXPRESSION "Expressway" STYLE WIDTH 2 COLOR 255 0 0 END END END LAYER NAME major_city_labels TYPE ANNOTATION STATUS ON MAXSCALE 1000000 DATA '../../../wwwroot/Data/mjcities' LABELITEM 'NAME' CLASS LABEL TYPE truetype FONT "calibri" SIZE 8 COLOR 0 0 0 OUTLINECOLOR 255 255 255 POSITION CC MINFEATURESIZE 100 END # End for label END # end for class PROJECTION "proj=latlong" "ellps=WGS84" END # End for projection END # End for layer LAYER NAME 'mjcities' TYPE POINT DUMP false EXTENT -148.317097 42.348600 -55.567680 86.032387 DATA '../../../wwwroot/Data/mjcities.shp' METADATA 'ows_title' 'mjcities' END STATUS ON MAXSCALE 2500000 TRANSPARENCY 100 PROJECTION 'proj=longlat' 'datum=WGS84' 'no_defs' END CLASS NAME 'mjcities' STYLE SYMBOL "S3" SIZE 17 OUTLINECOLOR 0 0 0 COLOR 0 0 255 END END END END -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Fri Apr 6 13:49:15 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Fri, 06 Apr 2012 16:49:15 -0400 Subject: [mapserver-users] Help! In-Reply-To: References: Message-ID: <4F7F56CB.90706@swoodbridge.com> What do you get if you try this url: http://localhost/cgi-bin/wms?MODE=map&MAP=C:/wwwroot/QGISMap/QGISMap.map&layers=province_dd -Steve W On 4/6/2012 4:17 PM, ?zg?r Arslan wrote: > > Hi All, > > I am new in open layers and I am trying to demonstrate my mapfile with > Open layers. Can some one helm me about this please? Code lines are below: > > > > > > OpenLayers Example > > > >
> > > > > > > > > # Map file created from QGIS project file > # Edit this file to customize for your map interface > # (Created with PyQgis MapServer Export plugin) > MAP > NAME "QGIS-MAP" > # Map image size > SIZE 500 500 > UNITS meters > STATUS ON > EXTENT -2400000 -900000 3100000 4000000 > FONTSET "/wwwroot/fonts/fontset.txt" > SYMBOLSET '../symbols/symbols.sty' > PROJECTION > "proj=lcc" > "ellps=GRS80" > "lat_0=49" > "lon_0=-95" > "lat_1=49" > "lat_2=77" > "datum=NAD83" > "units=m" > "no_defs <>" > END > > SYMBOL > NAME "S3" > TYPE pixmap > IMAGE '/wwwroot/symbols/S3.png' > END # SYMBOL > > # Background color for the map canvas -- change as desired > IMAGECOLOR 0 0 255 > IMAGEQUALITY 95 > IMAGETYPE png > CONFIG "CGI_CONTEXT_URL" "1" > OUTPUTFORMAT > NAME agg > DRIVER AGG/PNG > IMAGEMODE RGB > END > > > QUERYMAP > STATUS ON > SIZE 500 500 # sets the map to be queryable > STYLE HILITE # the selected object is highligthed > COLOR 0 255 0 > END # End for QueryMap > > SCALEBAR > STATUS EMBED > UNITS KILOMETERS > INTERVALS 3 > TRANSPARENT TRUE > OUTLINECOLOR 0 0 0 > END # End for scalebar > > # Legend > LEGEND > IMAGECOLOR 255 255 255 > STATUS ON > KEYSIZE 18 12 > LABEL > TYPE BITMAP > SIZE MEDIUM > COLOR 0 0 89 > END > END > > # Web interface definition. Only the template parameter > # is required to display a map. See MapServer documentation > WEB > # Set IMAGEPATH to the path where MapServer should > # write its output. > IMAGEPATH '/ms4w/tmp/ms_tmp/' > > # Set IMAGEURL to the url that points to IMAGEPATH > # as defined in your web server configuration > IMAGEURL '/ms_tmp/' > > HEADER "header.html" > FOOTER "footer.html" > EMPTY "/maps/QGISMap/blank.html" > > # WMS server settings > METADATA > 'ows_title' 'QGIS-MAP' > 'ows_onlineresource' > 'localhost/cgi-bin/mapserv.exe?map=C:/wwwroot/QGISMap/QGISMap.map' > 'ows_srs' 'EPSG:4326' > END > > #Scale range at which web interface will operate > # Template and header/footer settings > # Only the template parameter is required to display a map. See > MapServer documentation > TEMPLATE 'global.html' > END > > LAYER > NAME 'province_dd' > TYPE POLYGON > DUMP false > CONNECTION "http://localhost/cgi-bin/wms?" > CONNECTIONTYPE WMS > > EXTENT -148.317097 42.348600 -55.567680 86.032387 > DATA '../../../wwwroot/Data/province_dd.shp' > METADATA > 'wms_onlineresource' 'http://localhost/cgi-bin/mapserv.exe?map=wms.map&' > "wms_srs" "EPSG:4326" > "wms_name" "province_dd" > "wms_server_version" "1.1.1" > "wms_format" "image/gif" > #'ows_title' 'province_dd' > END > STATUS ON > TRANSPARENCY 100 > PROJECTION > 'proj=longlat' > 'datum=WGS84' > 'no_defs' > END > LABELITEM 'NAME_ENG' > CLASSITEM 'NAME_ENG' > CLASS > NAME "Alberta" > EXPRESSION "Alberta" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 130 9 169 > END > > END > CLASS > NAME "British Columbia" > EXPRESSION "British Columbia" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 62 106 166 > END > END > CLASS > NAME "Manitoba" > EXPRESSION "Manitoba" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 176 232 23 > END > END > CLASS > NAME "New Brunswick" > EXPRESSION "New Brunswick" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 248 188 159 > END > END > CLASS > NAME "Newfoundland" > EXPRESSION "Newfoundland" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 172 33 56 > END > END > CLASS > NAME "Northwest Territories" > EXPRESSION "Northwest Territories" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 123 03 213 > END > END > CLASS > NAME "Nova Scotia" > EXPRESSION "Nova Scotia" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 187 66 185 > END > END > CLASS > NAME "Nunavut" > EXPRESSION "Nunavut" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 171 222 109 > END > END > CLASS > NAME "Ontario" > EXPRESSION "Ontario" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 250 20 201 > END > END > CLASS > NAME "Prince Edward Island" > EXPRESSION "Prince Edward Island" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 69 153 254 > END > END > CLASS > NAME "Quebec" > EXPRESSION "Quebec" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 6 170 235 > END > END > CLASS > NAME "Saskatchewan" > EXPRESSION "Saskatchewan" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 251 167 144 > END > END > CLASS > NAME "Yukon Territory" > EXPRESSION "Yukon Territory" > STYLE > WIDTH 0.91 > OUTLINECOLOR 0 0 0 > COLOR 26 34 69 > END > END > END > > LAYER > NAME province_labels > TYPE ANNOTATION > STATUS ON > DATA '../../../wwwroot/Data/province_dd.shp' > LABELITEM 'NAME_ENG' > CLASS > LABEL > TYPE truetype > FONT "calibri" > SIZE 9 > COLOR 255 255 255 > OUTLINECOLOR 0 0 0 > POSITION CC > MINFEATURESIZE 100 > END # End for label > END # end for class > PROJECTION > "proj=latlong" > "ellps=WGS84" > END # End for projection > END # End for layer > > LAYER > NAME 'mjrroads' > TYPE LINE > DUMP false > EXTENT -148.317097 42.348600 -55.567680 86.032387 > DATA '../../../wwwroot/Data/mjrroads.shp' > METADATA > 'ows_title' 'mjrroads' > END > STATUS ON > TRANSPARENCY 100 > PROJECTION > 'proj=longlat' > 'datum=WGS84' > 'no_defs' > END > CLASSITEM 'TYPE' > > HEADER "mjrroads_header.html" > FOOTER "mjrroads_footer.html" > > TOLERANCE 5 > TOLERANCEUNITS PIXELS > > > CLASS > NAME "Primary Highway" > EXPRESSION "Primary Highway" > MAXSCALE 2500000 > TEMPLATE "mjrroads_query.html" > > STYLE > WIDTH 1 > COLOR 0 0 0 > END > END > CLASS > TEMPLATE "mjrroads_query.html" > NAME "Expressway" > EXPRESSION "Expressway" > STYLE > WIDTH 2 > COLOR 255 0 0 > END > END > END > > LAYER > NAME major_city_labels > TYPE ANNOTATION > STATUS ON > MAXSCALE 1000000 > DATA '../../../wwwroot/Data/mjcities' > LABELITEM 'NAME' > CLASS > LABEL > TYPE truetype > FONT "calibri" > SIZE 8 > COLOR 0 0 0 > OUTLINECOLOR 255 255 255 > POSITION CC > MINFEATURESIZE 100 > END # End for label > END # end for class > PROJECTION > "proj=latlong" > "ellps=WGS84" > END # End for projection > END # End for layer > > LAYER > NAME 'mjcities' > TYPE POINT > DUMP false > EXTENT -148.317097 42.348600 -55.567680 86.032387 > DATA '../../../wwwroot/Data/mjcities.shp' > METADATA > 'ows_title' 'mjcities' > END > > STATUS ON > MAXSCALE 2500000 > TRANSPARENCY 100 > PROJECTION > 'proj=longlat' > 'datum=WGS84' > 'no_defs' > END > CLASS > NAME 'mjcities' > STYLE > SYMBOL "S3" > SIZE 17 > OUTLINECOLOR 0 0 0 > COLOR 0 0 255 > END > > END > END > END > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From woodbri at swoodbridge.com Fri Apr 6 13:56:21 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Fri, 06 Apr 2012 16:56:21 -0400 Subject: [mapserver-users] placement of labels from two different In-Reply-To: <36CA828A36E29F45B7CF0A1766E5DFA30F7390@swmail01.r8nssis.local> References: <20120406160016.956DDE00D63@lists.osgeo.org> <36CA828A36E29F45B7CF0A1766E5DFA30F7390@swmail01.r8nssis.local> Message-ID: <4F7F5875.4080907@swoodbridge.com> You could also try using something like the following, one on each layer: POSITION CL ALIGN RIGHT OFFSET -5 0 POSITION CR ALIGN LEFT OFFSET 5 0 Obviously set 5 to a value that makes sense for you. Or you can use ALIGN CENTER and push the farther apart so the longest lines in each set does not interfere with the adjacent label. The problem with searching for open space is that it is hard and computationally expensive. -Steve On 4/6/2012 2:12 PM, Mark Volz wrote: > Steve, > > Thank you for your comments. I should have mentioned that I am using > multi-line labels so using position did not move the label over quite > enough. However, I was able to get the label to work by using offset > which allows me to get the label in closer than when I was using wrap > to create empty lines to move the label up. > > > I wish there were some better options for label placement such as fit > a second label inside the largest area of a polygon between current > labels and the polygon boundary. This way we could force secondary > labels to fit within the parcel. Second, it would also be nice if we > have a choice to make sure that the labels fit within the bbox, or > within the polygon boundary. That way we could make sure that labels > fit within the polygon for illregular shaped parcels such as a soils > layer. But of course those are unfunded thoughts. > > > Mark Volz GIS Specialist > > -----Original Message----- From: > mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of > mapserver-users-request at lists.osgeo.org Sent: Friday, April 06, 2012 > 11:00 AM To: mapserver-users at lists.osgeo.org Subject: mapserver-users > Digest, Vol 51, Issue 6 > > > Message: 5 Date: Fri, 06 Apr 2012 11:35:09 -0400 From: Stephen > Woodbridge Subject: Re: [mapserver-users] > placement of labels from two different polygons that have the same > feature shape To: mapserver-users at lists.osgeo.org > Message-ID:<4F7F0D2D.1090703 at swoodbridge.com> Content-Type: > text/plain; charset=ISO-8859-1; format=flowed > > On 4/6/2012 11:07 AM, Mark Volz wrote: >> Hello, I would like to label both parcel polygons, and lot polygons >> on my map. Unfortunately, if the parcel and the lot have the exact >> same boundary, only the parcel is labeled. Does anyone have any >> ideas or map files on how I could label both parcel polygons and >> lot polygons? Am I missing a keyword that when the parcel is >> labeled at the center of the bounding box, a secondary label for >> the lots could be placed within the open area of the boundary box? >> I asked this question last year, at the time one person suggested >> that I could convert my data into points, which has more labeling >> positions. Unfortunately, I would prefer not to convert my data >> into points for labeling as I would like to take advantage >> MINFEATURESIZE AUTO which only works with polygons. P.S. I found >> that the wrap keyword works so It is possible to label both parcels >> and lots. However, since extra lines are added the label might fall >> on top of the wrong lot if I zoom out too far. Thank you Mark Volz >> GIS Specialist > > Mark, > > The easiest way to do this is to do something like set the possition > of one to be UC and the other to be LC. you can also push them > farther apart by using OFFSET to move the upper one higher and the > lower one lower. > > You might also try POSITION AUTO, but if you use BUFFER this will not > help. > > -Steve W > > > ------------------------------ > > _______________________________________________ mapserver-users > mailing list mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > End of mapserver-users Digest, Vol 51, Issue 6 > ********************************************** > _______________________________________________ mapserver-users > mailing list mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From woodbri at swoodbridge.com Fri Apr 6 13:57:30 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Fri, 06 Apr 2012 16:57:30 -0400 Subject: [mapserver-users] placement of labels from two different In-Reply-To: <36CA828A36E29F45B7CF0A1766E5DFA30F7390@swmail01.r8nssis.local> References: <20120406160016.956DDE00D63@lists.osgeo.org> <36CA828A36E29F45B7CF0A1766E5DFA30F7390@swmail01.r8nssis.local> Message-ID: <4F7F58BA.3020506@swoodbridge.com> You could also try using something like the following, one on each layer: POSITION CL ALIGN RIGHT OFFSET -5 0 POSITION CR ALIGN LEFT OFFSET 5 0 Obviously set 5 to a value that makes sense for you. Or you can use ALIGN CENTER and push the farther apart so the longest lines in each set does not interfere with the adjacent label. The problem with searching for open space is that it is hard and computationally expensive. You would be better off precomputing a label point and create a separate layer for labeling. -Steve On 4/6/2012 2:12 PM, Mark Volz wrote: > Steve, > > Thank you for your comments. I should have mentioned that I am using > multi-line labels so using position did not move the label over quite > enough. However, I was able to get the label to work by using offset > which allows me to get the label in closer than when I was using wrap > to create empty lines to move the label up. > > > I wish there were some better options for label placement such as fit > a second label inside the largest area of a polygon between current > labels and the polygon boundary. This way we could force secondary > labels to fit within the parcel. Second, it would also be nice if we > have a choice to make sure that the labels fit within the bbox, or > within the polygon boundary. That way we could make sure that labels > fit within the polygon for illregular shaped parcels such as a soils > layer. But of course those are unfunded thoughts. > > > Mark Volz GIS Specialist > > -----Original Message----- From: > mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of > mapserver-users-request at lists.osgeo.org Sent: Friday, April 06, 2012 > 11:00 AM To: mapserver-users at lists.osgeo.org Subject: mapserver-users > Digest, Vol 51, Issue 6 > > > Message: 5 Date: Fri, 06 Apr 2012 11:35:09 -0400 From: Stephen > Woodbridge Subject: Re: [mapserver-users] > placement of labels from two different polygons that have the same > feature shape To: mapserver-users at lists.osgeo.org > Message-ID:<4F7F0D2D.1090703 at swoodbridge.com> Content-Type: > text/plain; charset=ISO-8859-1; format=flowed > > On 4/6/2012 11:07 AM, Mark Volz wrote: >> Hello, I would like to label both parcel polygons, and lot polygons >> on my map. Unfortunately, if the parcel and the lot have the exact >> same boundary, only the parcel is labeled. Does anyone have any >> ideas or map files on how I could label both parcel polygons and >> lot polygons? Am I missing a keyword that when the parcel is >> labeled at the center of the bounding box, a secondary label for >> the lots could be placed within the open area of the boundary box? >> I asked this question last year, at the time one person suggested >> that I could convert my data into points, which has more labeling >> positions. Unfortunately, I would prefer not to convert my data >> into points for labeling as I would like to take advantage >> MINFEATURESIZE AUTO which only works with polygons. P.S. I found >> that the wrap keyword works so It is possible to label both parcels >> and lots. However, since extra lines are added the label might fall >> on top of the wrong lot if I zoom out too far. Thank you Mark Volz >> GIS Specialist > > Mark, > > The easiest way to do this is to do something like set the possition > of one to be UC and the other to be LC. you can also push them > farther apart by using OFFSET to move the upper one higher and the > lower one lower. > > You might also try POSITION AUTO, but if you use BUFFER this will not > help. > > -Steve W > > > ------------------------------ > > _______________________________________________ mapserver-users > mailing list mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > End of mapserver-users Digest, Vol 51, Issue 6 > ********************************************** > _______________________________________________ mapserver-users > mailing list mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From thomas.bonfort at gmail.com Sat Apr 7 02:34:11 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Sat, 7 Apr 2012 11:34:11 +0200 Subject: [mapserver-users] [Announce] Change of source code repository and issue tracker Message-ID: The MapServer team is excited to announce it is migrating its source code repository and bug tracker to github. We believe this move will allow us to work more efficiently on new features and bugfixes, while facilitating exterior contributions. We now have 4 separate repositories for our different sub-projects: - mapserver: https://github.com/mapserver/mapserver - docs (website): https://github.com/mapserver/docs - tinyows: https://github.com/mapserver/tinyows - mapcache: https://github.com/mapserver/mapcache The old issue tracker at http://trac.osgeo.org/mapserver/ has been set to read-only. New issues, or updates to existing issues (issue numbers have been preserved) , should now be added at https://github.com/mapserver/mapserver/issues If you do not already have a github account, you will need to create one before being able to update the github site. Note that your github userid is different from your osgeo userid. The new issue tracker will not email you on ticket updates if you had reported or commented on an issue. If you wish to be notified on certain tickets, you should navigate to that specific issue page and enable notifications (near the bottom of the page). Notes for doc commits (including RFCs): - Commit access for the documentation contributors hasn't yet been fully accomplished. If you are a doc committer and need to be added to the github commiters, please send your github id and old osgeo id to daniel, steve or thomas who will open access for you. - You should commit doc changes to the stable branch (currently branch-6-0, soon branch-6-2) *only*. Updating the master branch (ex trunk) is done by merging the stable branch into it, and does not need to be done immediately (i.e. if you're not sure, only commit and push your changes to branch-6-0). The only exception for commiting to master is when you are documenting a feature that will be introduced in the next release. Best regards. From andy at f5data.com Sat Apr 7 14:11:08 2012 From: andy at f5data.com (Andrew Revering) Date: Sat, 7 Apr 2012 16:11:08 -0500 Subject: [mapserver-users] WMS Speed vs Direct URL Message-ID: I'm curious if anyone knows why WMS is SOOO much faster when I am loading my maps through a map (OpenLayers) than it is when I just try to pull a single tile directly through my brower and a WMS url? It seems like the server takes forever when I just enter a WMS URL into my browser's address bar, but when I load the same WMS map through OpenLayers its so much faster, despite loading all those seperate tiles individually instead of just the one I'm requesting in the browser. Any ideas? -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Sat Apr 7 15:50:00 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Sat, 07 Apr 2012 18:50:00 -0400 Subject: [mapserver-users] WMS Speed vs Direct URL In-Reply-To: References: Message-ID: <4F80C498.7010106@swoodbridge.com> On 4/7/2012 5:11 PM, Andrew Revering wrote: > I'm curious if anyone knows why WMS is SOOO much faster when I am > loading my maps through a map (OpenLayers) than it is when I just try to > pull a single tile directly through my brower and a WMS url? > > It seems like the server takes forever when I just enter a WMS URL into > my browser's address bar, but when I load the same WMS map through > OpenLayers its so much faster, despite loading all those seperate tiles > individually instead of just the one I'm requesting in the browser. > > Any ideas? Browser caching maybe? -Steve From pcreso at pcreso.com Sat Apr 7 15:59:54 2012 From: pcreso at pcreso.com (pcreso at pcreso.com) Date: Sat, 7 Apr 2012 15:59:54 -0700 (PDT) Subject: [mapserver-users] WMS Speed vs Direct URL In-Reply-To: <4F80C498.7010106@swoodbridge.com> Message-ID: <1333839594.56641.YahooMailClassic@web160704.mail.bf1.yahoo.com> Is OL accessing via a tile cache whereas the direct URL is rendering on the fly? On 4/7/2012 5:11 PM, Andrew Revering wrote: > I'm curious if anyone knows why WMS is SOOO much faster when I am > loading my maps through a map (OpenLayers) than it is when I just try to > pull a single tile directly through my brower and a WMS url? > > It seems like the server takes forever when I just enter a WMS URL into > my browser's address bar, but when I load the same WMS map through > OpenLayers its so much faster, despite loading all those seperate tiles > individually instead of just the one I'm requesting in the browser. > > Any ideas? -------------- next part -------------- An HTML attachment was scrubbed... URL: From john.callahan at udel.edu Sat Apr 7 20:58:46 2012 From: john.callahan at udel.edu (John Callahan) Date: Sat, 7 Apr 2012 23:58:46 -0400 Subject: [mapserver-users] WMS Speed vs Direct URL In-Reply-To: References: Message-ID: Is the one tile your are requesting directly through your browser the same size (in pixels, say 256x256) than each tile being displayed through OL? Or is the image requested through the browser much larger in extent and size than a single OL tile? - John On Sat, Apr 7, 2012 at 5:11 PM, Andrew Revering wrote: > I'm curious if anyone knows why WMS is SOOO much faster when I am loading > my maps through a map (OpenLayers) than it is when I just try to pull a > single tile directly through my brower and a WMS url? > > It seems like the server takes forever when I just enter a WMS URL into my > browser's address bar, but when I load the same WMS map through OpenLayers > its so much faster, despite loading all those seperate tiles individually > instead of just the one I'm requesting in the browser. > > Any ideas? > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Sun Apr 8 21:14:28 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Mon, 9 Apr 2012 04:14:28 +0000 Subject: [mapserver-users] Hellp please!! Message-ID: HI All, I am working on open layers and map file and I have a question. I am trying to create several layers from 1 map file on open layers, and I want to switch off and on but I couldn't separate the layers in OpenLayers. When I set layers to DEFAULT in map file it displays all layers together like a one layer. I can't create different layers from one map file. Are there any ideas? Codes are below; Thank you OpenLayers Example
-------------- next part -------------- An HTML attachment was scrubbed... URL: From venkat.shesu at gmail.com Sun Apr 8 21:21:18 2012 From: venkat.shesu at gmail.com (Venkat Shesu Reddem) Date: Mon, 9 Apr 2012 09:51:18 +0530 Subject: [mapserver-users] Hellp please!! In-Reply-To: References: Message-ID: Dear Friend, This may be help you. .................. ................. layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," http://localhost/cgi-bin/mapserv.exe", {layers: 'ResidentDistrict_2011',map: '/wwwroot/example1_test/Canada_Mountains.map',} ) layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: '/wwwroot/example1_test/Canada_Mountains.map',} ) layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," http://localhost/cgi-bin/mapserv.exe", {layers: 'MDI_2011',map: '/wwwroot/example1_test/Canada_Mountains.map',} ) map.addLayers([ResidentDistrict_2011, LAKES, MDI_2011]); ................... .................. with regards Venkat On Mon, Apr 9, 2012 at 9:44 AM, ?zg?r Arslan wrote: > HI All, > > I am working on open layers and map file and I have a question. I am > trying to create several layers from 1 map file on open layers, and I want > to switch off and on but I couldn't separate the layers in OpenLayers. When > I set layers to DEFAULT in map file it displays all layers together like a > one layer. I can't create different layers from one map file. Are there any > ideas? Codes are below; > > Thank you > > > > > > OpenLayers Example > type="text/css"> > > > >
> > > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From venkat.shesu at gmail.com Sun Apr 8 21:22:39 2012 From: venkat.shesu at gmail.com (Venkat Shesu Reddem) Date: Mon, 9 Apr 2012 09:52:39 +0530 Subject: [mapserver-users] Hellp please!! In-Reply-To: References: Message-ID: Sorry for previous mail. layer1 = new OpenLayers.Layer.WMS( "QGIS-MAP"," http://localhost/cgi-bin/mapserv.exe", {layers: 'ResidentDistrict_2011',map: '/wwwroot/example1_test/Canada_Mountains.map',} ) layer2 = new OpenLayers.Layer.WMS( "QGIS-MAP"," http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: '/wwwroot/example1_test/Canada_Mountains.map',} ) layer3 = new OpenLayers.Layer.WMS( "QGIS-MAP"," http://localhost/cgi-bin/mapserv.exe", {layers: 'MDI_2011',map: '/wwwroot/example1_test/Canada_Mountains.map',} ) map.addLayers([layer1,layer2,layer3]); with regards Venkat On Mon, Apr 9, 2012 at 9:51 AM, Venkat Shesu Reddem wrote: > Dear Friend, > > This may be help you. > .................. > ................. > layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: > 'ResidentDistrict_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'MDI_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > map.addLayers([ResidentDistrict_2011, LAKES, MDI_2011]); > > ................... > .................. > > with regards > Venkat > > On Mon, Apr 9, 2012 at 9:44 AM, ?zg?r Arslan wrote: > >> HI All, >> >> I am working on open layers and map file and I have a question. I am >> trying to create several layers from 1 map file on open layers, and I want >> to switch off and on but I couldn't separate the layers in OpenLayers. When >> I set layers to DEFAULT in map file it displays all layers together like a >> one layer. I can't create different layers from one map file. Are there any >> ideas? Codes are below; >> >> Thank you >> >> >> >> >> >> OpenLayers Example >> > type="text/css"> >> >> >> >>
>> >> >> >> >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Sun Apr 8 21:44:56 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Mon, 9 Apr 2012 04:44:56 +0000 Subject: [mapserver-users] (no subject) Message-ID: Dear Venkat Thank you for your suggestion I really appreciate it but it didn't work. Do you have another idea to share with me please? Thanks again Ozz -------------- next part -------------- An HTML attachment was scrubbed... URL: From fernando at globalgeo.com.br Mon Apr 9 04:35:15 2012 From: fernando at globalgeo.com.br (Fernando Norte) Date: Mon, 9 Apr 2012 08:35:15 -0300 Subject: [mapserver-users] Hellp please!! In-Reply-To: References: Message-ID: Ozgur, Change the STATUS to ON at the mapfile, and the Venkar suggestion probably will works. The DEFAULT at STATUS make the layer allways visible. And the ON make then visible at LAYER declararion. My regards, 2012/4/9 Venkat Shesu Reddem > Sorry for previous mail. > > layer1 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: > 'ResidentDistrict_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer2 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer3 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'MDI_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > map.addLayers([layer1,layer2,layer3]); > > with regards > Venkat > > > > On Mon, Apr 9, 2012 at 9:51 AM, Venkat Shesu Reddem < > venkat.shesu at gmail.com> wrote: > >> Dear Friend, >> >> This may be help you. >> .................. >> ................. >> layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," >> http://localhost/cgi-bin/mapserv.exe", {layers: >> 'ResidentDistrict_2011',map: >> '/wwwroot/example1_test/Canada_Mountains.map',} ) >> >> layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," >> http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: >> '/wwwroot/example1_test/Canada_Mountains.map',} ) >> >> layer = new OpenLayers.Layer.WMS( "QGIS-MAP"," >> http://localhost/cgi-bin/mapserv.exe", {layers: 'MDI_2011',map: >> '/wwwroot/example1_test/Canada_Mountains.map',} ) >> >> map.addLayers([ResidentDistrict_2011, LAKES, MDI_2011]); >> >> ................... >> .................. >> >> with regards >> Venkat >> >> On Mon, Apr 9, 2012 at 9:44 AM, ?zg?r Arslan wrote: >> >>> HI All, >>> >>> I am working on open layers and map file and I have a question. I am >>> trying to create several layers from 1 map file on open layers, and I want >>> to switch off and on but I couldn't separate the layers in OpenLayers. When >>> I set layers to DEFAULT in map file it displays all layers together like a >>> one layer. I can't create different layers from one map file. Are there any >>> ideas? Codes are below; >>> >>> Thank you >>> >>> >>> >>> >>> >>> OpenLayers Example >>> >> type="text/css"> >>> >>> >>> >>>
>>> >>> >>> >>> >>> >>> >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> >>> >> > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Mon Apr 9 13:00:37 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Mon, 9 Apr 2012 20:00:37 +0000 Subject: [mapserver-users] RE: mapserver-users Digest, Vol 51, Issue 11 In-Reply-To: <20120409160016.10482E00BF5@lists.osgeo.org> References: <20120409160016.10482E00BF5@lists.osgeo.org> Message-ID: Hi ALL, Thanks for all responds. I tryed all suggestions and when I use these lines it only shows layer1 like a base map and I can't switch off and on. I would like create 3 separate layer that I can switch off and on each layer individually. Furthermore when I change the layer orders from map.addLayers([layer1,layer2,layer3]); to map.addLayers([layer2,layer1,layer3]); this time it only shows the second layer(layer2) as a base layer and I can't switch off and on. Could you please share your ideas with me about the issue? Thank you layer1 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: > 'ResidentDistrict_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer2 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer3 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'BDI_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > map.addLayers([layer1,layer2,layer3]); here are the html codes OpenLayers Example
-------------- next part -------------- An HTML attachment was scrubbed... URL: From fernando at globalgeo.com.br Mon Apr 9 13:18:22 2012 From: fernando at globalgeo.com.br (Fernando Norte) Date: Mon, 9 Apr 2012 17:18:22 -0300 Subject: [mapserver-users] RE: mapserver-users Digest, Vol 51, Issue 11 In-Reply-To: References: <20120409160016.10482E00BF5@lists.osgeo.org> Message-ID: Ozgur, You said that layers are BASE layers. Base layers can't switch to off an on, there is only one base layer active, there you can switch between them. Are you using the OpenLayers.Control.LayerSwitcher, to see the layers? In the openlayers.layer.wms you can set this as not a base layer, as options.. after {}, { isBaseLayer: false } But remember a base layer need to exist, and there is a way to include a 'blank' layer as base layer. Good luck, 2012/4/9 ?zg?r Arslan > Hi ALL, > > Thanks for all responds. I tryed all suggestions and when I use these > lines it only shows layer1 like a base map and I can't switch off and on. I > would like create 3 separate layer that I can switch off and on each layer > individually. > > Furthermore when I change the layer orders from map.addLayers([layer1,layer2,layer3]); to map.addLayers([layer2,layer1,layer3]); this time it only shows > the second layer(layer2) as a base layer and I can't switch off and on. Could you please share your ideas with me about the issue? > > Thank you > > > layer1 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > > http://localhost/cgi-bin/mapserv.exe", {layers: > > 'ResidentDistrict_2011',map: > > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > > > layer2 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > > http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: > > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > > > layer3 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > > http://localhost/cgi-bin/mapserv.exe", {layers: 'BDI_2011',map: > > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > > > map.addLayers([layer1,layer2,layer3]); > > > *here are the html codes* > > > > > OpenLayers Example > > > > > > >
> > > > > > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Mon Apr 9 13:44:26 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Mon, 9 Apr 2012 20:44:26 +0000 Subject: [mapserver-users] RE: mapserver-users Digest, Vol 51, Issue 11 In-Reply-To: References: <20120409160016.10482E00BF5@lists.osgeo.org>, , Message-ID: Fernando,fernando at globalgeo.com.br mapserver-users at lists.osgeo.org Thanks for your respond I really appreciate it. Also yes I am using map.addControl(new OpenLayers.Control.LayerSwitcher()); In this Html codes how can I create a second layer by using same map file that I can switch off and on near the base map? My html file is below: Thanks again. OpenLayers Example
Date: Mon, 9 Apr 2012 17:18:22 -0300 Subject: Re: [mapserver-users] RE: mapserver-users Digest, Vol 51, Issue 11 From: fernando at globalgeo.com.br To: ozgurarslan81 at hotmail.com CC: mapserver-users at lists.osgeo.org Ozgur, You said that layers are BASE layers. Base layers can't switch to off an on, there is only one base layer active, there you can switch between them. Are you using the OpenLayers.Control.LayerSwitcher, to see the layers? In the openlayers.layer.wms you can set this as not a base layer, as options.. after {}, { isBaseLayer: false }But remember a base layer need to exist, and there is a way to include a 'blank' layer as base layer. Good luck, 2012/4/9 ?zg?r Arslan Hi ALL, Thanks for all responds. I tryed all suggestions and when I use these lines it only shows layer1 like a base map and I can't switch off and on. I would like create 3 separate layer that I can switch off and on each layer individually. Furthermore when I change the layer orders from map.addLayers([layer1,layer2,layer3]); to map.addLayers([layer2,layer1,layer3]); this time it only shows the second layer(layer2) as a base layer and I can't switch off and on. Could you please share your ideas with me about the issue? Thank you layer1 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: > 'ResidentDistrict_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer2 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'LAKES',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > layer3 = new OpenLayers.Layer.WMS( "QGIS-MAP"," > http://localhost/cgi-bin/mapserv.exe", {layers: 'BDI_2011',map: > '/wwwroot/example1_test/Canada_Mountains.map',} ) > > map.addLayers([layer1,layer2,layer3]); here are the html codes OpenLayers Example
_______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Mon Apr 9 15:00:33 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Mon, 9 Apr 2012 22:00:33 +0000 Subject: [mapserver-users] Help Message-ID: Hi all, Thanks for your respond I really appreciate it. I am using map.addControl(new OpenLayers.Control.LayerSwitcher()); In this Html codes how can I create a second layer by using same map file that I can switch off and on near the base map? My html file is below: Thanks again. OpenLayers Example
-------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Mon Apr 9 19:52:09 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Tue, 10 Apr 2012 02:52:09 +0000 Subject: [mapserver-users] RE: In-Reply-To: References: , Message-ID: Dear Venkat, You were right your last suggestion worked very well. Thank you so much I really appreciate it. Have a nice day. Ozz Date: Mon, 9 Apr 2012 11:49:10 +0530 Subject: Re: From: venkat.shesu at gmail.com To: ozgurarslan81 at hotmail.com Dear Ozz, Me too developing same sort of application, by using OpenLayers creating several layers from single mapfile. which looks something like this: :::::::::::::::::::: mainURL = "/cgi-bin/mapserv54?map=ODIS_MAPFILE"; map = new OpenLayers.Map({ div: "map", maxExtent: new OpenLayers.Bounds(20,-70,120,30), restrictedExtent: new OpenLayers.Bounds(20,-70,120,30) }); ocean = new OpenLayers.Layer.WMS("Indian Ocean", mainURL, {'layers': 'ocean', transparent: true, format: 'image/gif'}, {isBaseLayer: true} ); moored = new OpenLayers.Layer.WMS("Moored Buoys", mainURL, {'layers': 'moored', transparent: true, format: 'image/gif'}, {isBaseLayer: false} ); drifting = new OpenLayers.Layer.WMS("Drifting Buoys", mainURL, {'layers': 'drifting', transparent: true, format: 'image/gif'}, {isBaseLayer: false} ); map.addLayers([ocean, moored, drifting]); :::::::::::::::::::::::::::::::::::::::::: And its work properly with my existing setup, you may customized these lines of code for whatever 3 layers you have mentioned in your previous mail. with best regards Venkat. On Mon, Apr 9, 2012 at 10:14 AM, ?zg?r Arslan wrote: Dear Venkat Thank you for your suggestion I really appreciate it but it didn't work. Do you have another idea to share with me please? Thanks again Ozz -------------- next part -------------- An HTML attachment was scrubbed... URL: From K.Hirst at bom.gov.au Mon Apr 9 22:12:38 2012 From: K.Hirst at bom.gov.au (Kathleen Hirst) Date: Tue, 10 Apr 2012 15:12:38 +1000 Subject: [mapserver-users] GetLegendGraphic when using MINSIZE/MAXSIZE [SEC=UNCLASSIFIED] Message-ID: Dear List, When using MINSIZE and MAXSIZE for symbols in the mapfile, the GetLegendGraphic request seems to default to the MINSIZE. Is there a way that GetLegendGraphic can draw the symbol at the MAXSIZE? Thanks Kathleen -------------- next part -------------- An HTML attachment was scrubbed... URL: From neelima.emmani at iictechnologies.com Mon Apr 9 23:02:14 2012 From: neelima.emmani at iictechnologies.com (Neelima Emmani) Date: Tue, 10 Apr 2012 06:02:14 +0000 Subject: [mapserver-users] GetFeatureInfo results: Search returned no results Message-ID: Hi All, I am having a problem in retrieving getfeatureinfo. Result in the browser is GetFeatureInfo results: Search returned no results. * Below is the url, i am accessing to get feature info - http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&Layers=maps&SRS=EPSG:4326&BBOX=-83.61145,24.726875,-78.118286,27.196014&X=529&Y=228&WIDTH=1000&HEIGHT=500&QUERY_LAYERS=maps * Map file - MAP NAME "MH" # Map image size SIZE 600 600 UNITS meters EXTENT -86.731680 24.422064 -76.149835 30.424575 FONTSET './etc/fonts.txt' SYMBOLSET './etc/symbols.txt' CONFIG "PROJ_LIB" "C:/ms4w/httpd.d/proj/nad/" PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END # Background color for the map canvas -- change as desired IMAGECOLOR 255 255 255 IMAGEQUALITY 95 IMAGETYPE agg OUTPUTFORMAT NAME agg DRIVER AGG/PNG IMAGEMODE RGB END # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/ms4w/tmp/ms_tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/ms_tmp/' # WMS server settings METADATA 'ows_title' 'MH' 'ows_onlineresource' 'http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&' 'ows_srs' 'EPSG:4326 EPSG:900913' 'ows_enable_request' 'GetMap GetFeature GetFeatureInfo *' ##necessary "wms_feature_info_mime_type" "text/html" "wms_getfeatureinfo" "http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&" "wms_featureinfoformat" "text/html" "wfs_abstract" "This text describes my WFS service." END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation TEMPLATE 'template.html' END LAYER NAME 'maps' TYPE POINT DUMP true TEMPLATE 'template.html' HEADER 'header.html' FOOTER 'footer.html' EXTENT -86.731680 24.422064 -76.149835 30.424575 CONNECTIONTYPE postgis CONNECTION "dbname='postgis' host=localhost port=5432 user='postgres' password='xxxxxx' sslmode=disable" DATA 'the_geom FROM "maps" USING UNIQUE id USING srid=4326' FILTER ( geometrytype("the_geom") IN ('POINT','MULTIPOINT') ) METADATA 'ows_title' 'maps' 'wfs_typename' 'maps' 'wfs_version' '1.0.0' 'wfs_connectiontimeout' '60' 'wfs_maxfeatures' '150' 'wfs_filter' 'GET' 'wms_include_items' 'all' 'wfs_featureid' 'the_geom' 'gml_include_items' 'all' END STATUS OFF TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END CLASS NAME 'maps' STYLE SYMBOL "circle" SIZE 7.0 OUTLINECOLOR 0 0 0 COLOR 170 211 227 END END END END Template.html -- [lrn][NAME][LAT][LON][ELEVATION][QUADNAME] header.html-- Layer: airports

footer.html --
 namelatitudelongitudeaddressdescription

If any finds any fault with my code or anything that should be added to get feature info then please let me know. Awaiting reply. With Regards, Neelima Emmani -------------- next part -------------- An HTML attachment was scrubbed... URL: From Andreas.Eichner at sid.sachsen.de Mon Apr 9 23:55:46 2012 From: Andreas.Eichner at sid.sachsen.de (Eichner, Andreas - SID-NLKM) Date: Tue, 10 Apr 2012 08:55:46 +0200 Subject: AW: [mapserver-users] Help installing mapserver 4.10.7 References: <1333742386.26492.YahooMailNeo@web162001.mail.bf1.yahoo.com> Message-ID: <56B587E7C40D2F43B54FDC1BA897AC6D037AF322@KS-EVS1.smi.sachsen.de> This file will be auto-created by the build process using flex. You should be able to directly install it from Red Hat repos via # yum install flex HTH > -----Urspr?ngliche Nachricht----- > Von: mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Erica > Gesendet: Freitag, 6. April 2012 22:00 > An: mapserver-users at lists.osgeo.org > Betreff: [mapserver-users] Help installing mapserver 4.10.7 > > I'm attempting to install mapserver 4.10.7 on RHEL 5.6 > (kernel 2.6.18-238.35.1.el5). > > Configure works successfully, but I get the following error > when running make: > > : -Pmsyy -i -omaplexer.c maplexer.l > gcc -c -O2 -fPIC -Wall -DHAVE_VSNPRINTF -DNEED_STRLCAT > -DUSE_EPPL -DUSE_JPEG -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG > -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW > -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS -DUSE_ICONV > -DUSE_ZLIB -I/usr/include maplexer.c -o maplexer.o > gcc: maplexer.c: No such file or directory > gcc: no input files > make: *** [maplexer.o] Error 1 > > maplexer.c does not appear to exist either in the tarball or > in the branches for 4.10.7. maplexer.o is the only file > present. Has anybody encountered this before? What's the workaround? > > Thanks. > > > > From Jukka.Rahkonen at mmmtike.fi Mon Apr 9 23:59:23 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Tue, 10 Apr 2012 06:59:23 +0000 Subject: [mapserver-users] GetFeatureInfo results: Search returned no results In-Reply-To: References: Message-ID: <84446DEF76453C439E9E97E438E13A63149748@suutari.haapa.mmm.fi> Hi, Perhaps you do not hit the points? See tolerance and toleranceunits in http://mapserver.org/mapfile/layer.html and set tolerance to quite many pixels for eliminating the possibility that your click just does not hit the target. If that does not help I would have another try by copying the data from PostGIS ?nto shapefile and dublicating the layer. If GetFeatureInfo works with shapefile then the trouble must have something to do with communication with PostGIS. I wonder why do you have layer status=OFF instead of ON. -Jukka Rahkonen- Neelima Emmani wrote: Hi All, I am having a problem in retrieving getfeatureinfo. Result in the browser is GetFeatureInfo results: Search returned no results. * Below is the url, i am accessing to get feature info - http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&Layers=maps&SRS=EPSG:4326&BBOX=-83.61145,24.726875,-78.118286,27.196014&X=529&Y=228&WIDTH=1000&HEIGHT=500&QUERY_LAYERS=maps * Map file - MAP NAME "MH" # Map image size SIZE 600 600 UNITS meters EXTENT -86.731680 24.422064 -76.149835 30.424575 FONTSET './etc/fonts.txt' SYMBOLSET './etc/symbols.txt' CONFIG "PROJ_LIB" "C:/ms4w/httpd.d/proj/nad/" PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END # Background color for the map canvas -- change as desired IMAGECOLOR 255 255 255 IMAGEQUALITY 95 IMAGETYPE agg OUTPUTFORMAT NAME agg DRIVER AGG/PNG IMAGEMODE RGB END # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/ms4w/tmp/ms_tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/ms_tmp/' # WMS server settings METADATA 'ows_title' 'MH' 'ows_onlineresource' 'http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&' 'ows_srs' 'EPSG:4326 EPSG:900913' 'ows_enable_request' 'GetMap GetFeature GetFeatureInfo *' ##necessary "wms_feature_info_mime_type" "text/html" "wms_getfeatureinfo" "http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&" "wms_featureinfoformat" "text/html" "wfs_abstract" "This text describes my WFS service." END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation TEMPLATE 'template.html' END LAYER NAME 'maps' TYPE POINT DUMP true TEMPLATE 'template.html' HEADER 'header.html' FOOTER 'footer.html' EXTENT -86.731680 24.422064 -76.149835 30.424575 CONNECTIONTYPE postgis CONNECTION "dbname='postgis' host=localhost port=5432 user='postgres' password='xxxxxx' sslmode=disable" DATA 'the_geom FROM "maps" USING UNIQUE id USING srid=4326' FILTER ( geometrytype("the_geom") IN ('POINT','MULTIPOINT') ) METADATA 'ows_title' 'maps' 'wfs_typename' 'maps' 'wfs_version' '1.0.0' 'wfs_connectiontimeout' '60' 'wfs_maxfeatures' '150' 'wfs_filter' 'GET' 'wms_include_items' 'all' 'wfs_featureid' 'the_geom' 'gml_include_items' 'all' END STATUS OFF TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END CLASS NAME 'maps' STYLE SYMBOL "circle" SIZE 7.0 OUTLINECOLOR 0 0 0 COLOR 170 211 227 END END END END Template.html -- [lrn][NAME][LAT][LON][ELEVATION][QUADNAME] header.html-- Layer: airports

footer.html --
 namelatitudelongitudeaddressdescription

If any finds any fault with my code or anything that should be added to get feature info then please let me know. Awaiting reply. With Regards, Neelima Emmani -------------- next part -------------- An HTML attachment was scrubbed... URL: From neelima.emmani at iictechnologies.com Tue Apr 10 02:11:41 2012 From: neelima.emmani at iictechnologies.com (Neelima Emmani) Date: Tue, 10 Apr 2012 09:11:41 +0000 Subject: [mapserver-users] GetFeatureInfo results: Search returned no results In-Reply-To: <84446DEF76453C439E9E97E438E13A63149748@suutari.haapa.mmm.fi> References: , <84446DEF76453C439E9E97E438E13A63149748@suutari.haapa.mmm.fi> Message-ID: Hi Rahkonen, Tried giving Tolerance as 3 and it's units as meters , but it did not work. Also tried with the mapfile that has shapefile layer. The case is same. Do you any other idea that can solve my problem. And if you have already worked on this can you please send a piece of code that works. With Regards, Neelima Emmani ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] on behalf of Rahkonen Jukka [Jukka.Rahkonen at mmmtike.fi] Sent: Tuesday, April 10, 2012 12:29 PM To: 'mapserver-users at lists.osgeo.org' Subject: Re: [mapserver-users] GetFeatureInfo results: Search returned no results Hi, Perhaps you do not hit the points? See tolerance and toleranceunits in http://mapserver.org/mapfile/layer.html and set tolerance to quite many pixels for eliminating the possibility that your click just does not hit the target. If that does not help I would have another try by copying the data from PostGIS ?nto shapefile and dublicating the layer. If GetFeatureInfo works with shapefile then the trouble must have something to do with communication with PostGIS. I wonder why do you have layer status=OFF instead of ON. -Jukka Rahkonen- Neelima Emmani wrote: Hi All, I am having a problem in retrieving getfeatureinfo. Result in the browser is GetFeatureInfo results: Search returned no results. * Below is the url, i am accessing to get feature info - http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&Layers=maps&SRS=EPSG:4326&BBOX=-83.61145,24.726875,-78.118286,27.196014&X=529&Y=228&WIDTH=1000&HEIGHT=500&QUERY_LAYERS=maps * Map file - MAP NAME "MH" # Map image size SIZE 600 600 UNITS meters EXTENT -86.731680 24.422064 -76.149835 30.424575 FONTSET './etc/fonts.txt' SYMBOLSET './etc/symbols.txt' CONFIG "PROJ_LIB" "C:/ms4w/httpd.d/proj/nad/" PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END # Background color for the map canvas -- change as desired IMAGECOLOR 255 255 255 IMAGEQUALITY 95 IMAGETYPE agg OUTPUTFORMAT NAME agg DRIVER AGG/PNG IMAGEMODE RGB END # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/ms4w/tmp/ms_tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/ms_tmp/' # WMS server settings METADATA 'ows_title' 'MH' 'ows_onlineresource' 'http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&' 'ows_srs' 'EPSG:4326 EPSG:900913' 'ows_enable_request' 'GetMap GetFeature GetFeatureInfo *' ##necessary "wms_feature_info_mime_type" "text/html" "wms_getfeatureinfo" "http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&" "wms_featureinfoformat" "text/html" "wfs_abstract" "This text describes my WFS service." END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation TEMPLATE 'template.html' END LAYER NAME 'maps' TYPE POINT DUMP true TEMPLATE 'template.html' HEADER 'header.html' FOOTER 'footer.html' EXTENT -86.731680 24.422064 -76.149835 30.424575 CONNECTIONTYPE postgis CONNECTION "dbname='postgis' host=localhost port=5432 user='postgres' password='xxxxxx' sslmode=disable" DATA 'the_geom FROM "maps" USING UNIQUE id USING srid=4326' FILTER ( geometrytype("the_geom") IN ('POINT','MULTIPOINT') ) METADATA 'ows_title' 'maps' 'wfs_typename' 'maps' 'wfs_version' '1.0.0' 'wfs_connectiontimeout' '60' 'wfs_maxfeatures' '150' 'wfs_filter' 'GET' 'wms_include_items' 'all' 'wfs_featureid' 'the_geom' 'gml_include_items' 'all' END STATUS OFF TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END CLASS NAME 'maps' STYLE SYMBOL "circle" SIZE 7.0 OUTLINECOLOR 0 0 0 COLOR 170 211 227 END END END END Template.html -- [lrn][NAME][LAT][LON][ELEVATION][QUADNAME] header.html-- Layer: airports

footer.html --
 namelatitudelongitudeaddressdescription

If any finds any fault with my code or anything that should be added to get feature info then please let me know. Awaiting reply. With Regards, Neelima Emmani -------------- next part -------------- An HTML attachment was scrubbed... URL: From remon.sadikni at zmaw.de Tue Apr 10 02:00:38 2012 From: remon.sadikni at zmaw.de (Remon Sadikni) Date: Tue, 10 Apr 2012 11:00:38 +0200 Subject: [mapserver-users] osgeo mapserver error Message-ID: <4F83F6B6.9080007@zmaw.de> Dear mapserver team, today the osgeo mapserver gives the following error message instead of a map: msDrawMap(): Image handling error ... Unable to access file. (/mapdata/vmap0/disp/ceasefire_v0sas_4) It is the result of this request from our Live Access Server: http://vmap0.tiles.osgeo.org/wms/vmap0?FORMAT=image%2Fpng&LAYERS=basic&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&SRS=EPSG%3A4326&BBOX=-180,-90,180,270&WIDTH=256&HEIGHT=256 Thank you and best regards, Remon -- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Dipl. Inf. Remon Sadikni Scientific Programmer University of Hamburg / KlimaCampus Hamburg Center for Integrated Climate System Analysis and Prediction - CliSAP Grindelberg 5 / D-20144 Hamburg / Germany phone: +49-40-42838-7581 email: remon.sadikni at zmaw.de +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ From Jukka.Rahkonen at mmmtike.fi Tue Apr 10 02:55:28 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Tue, 10 Apr 2012 09:55:28 +0000 Subject: VS: [mapserver-users] GetFeatureInfo results: Search returned no results In-Reply-To: References: , <84446DEF76453C439E9E97E438E13A63149748@suutari.haapa.mmm.fi> Message-ID: <84446DEF76453C439E9E97E438E13A6314979A@suutari.haapa.mmm.fi> Hi, You do not want to use meters as tolerance units. Use pixels. The default is 3, try to increase it to 10 or something. I did not find any point layer we use with GetFeatureInfo but this one works for polygon shapefile LAYER NAME "Natura2000" STATUS ON DATA "\Data\natura06_poly" TYPE POLYGON DUMP TRUE UNITS METERS SIZEUNITS PIXELS TOLERANCE 3 HEADER "d:\data\template\natura_header.html" TEMPLATE "d:\data\template\natura_template.html" FOOTER "d:\data\template\natura_footer.html" TOLERANCEUNITS PIXELS METADATA "wms_include_items" "SPA,SCI,SCI2" "gml_include_items" "all" "wms_title" "Natura2000" "wms_srs" "EPSG:2393 EPSG:3067 EPSG:4326" END CLASS NAME "Natura2000" STYLE COLOR 200 50 0 END END PROJECTION "init=epsg:2393" END END -Jukka Rahkonen- ________________________________ L?hett?j?: Neelima Emmani [mailto:neelima.emmani at iictechnologies.com] L?hetetty: 10. huhtikuuta 2012 12:12 Vastaanottaja: Rahkonen Jukka Kopio: mapserver-users at lists.osgeo.org Aihe: RE: [mapserver-users] GetFeatureInfo results: Search returned no results Hi Rahkonen, Tried giving Tolerance as 3 and it's units as meters , but it did not work. Also tried with the mapfile that has shapefile layer. The case is same. Do you any other idea that can solve my problem. And if you have already worked on this can you please send a piece of code that works. With Regards, Neelima Emmani ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] on behalf of Rahkonen Jukka [Jukka.Rahkonen at mmmtike.fi] Sent: Tuesday, April 10, 2012 12:29 PM To: 'mapserver-users at lists.osgeo.org' Subject: Re: [mapserver-users] GetFeatureInfo results: Search returned no results Hi, Perhaps you do not hit the points? See tolerance and toleranceunits in http://mapserver.org/mapfile/layer.html and set tolerance to quite many pixels for eliminating the possibility that your click just does not hit the target. If that does not help I would have another try by copying the data from PostGIS ?nto shapefile and dublicating the layer. If GetFeatureInfo works with shapefile then the trouble must have something to do with communication with PostGIS. I wonder why do you have layer status=OFF instead of ON. -Jukka Rahkonen- Neelima Emmani wrote: Hi All, I am having a problem in retrieving getfeatureinfo. Result in the browser is GetFeatureInfo results: Search returned no results. * Below is the url, i am accessing to get feature info - http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&Layers=maps&SRS=EPSG:4326&BBOX=-83.61145,24.726875,-78.118286,27.196014&X=529&Y=228&WIDTH=1000&HEIGHT=500&QUERY_LAYERS=maps * Map file - MAP NAME "MH" # Map image size SIZE 600 600 UNITS meters EXTENT -86.731680 24.422064 -76.149835 30.424575 FONTSET './etc/fonts.txt' SYMBOLSET './etc/symbols.txt' CONFIG "PROJ_LIB" "C:/ms4w/httpd.d/proj/nad/" PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END # Background color for the map canvas -- change as desired IMAGECOLOR 255 255 255 IMAGEQUALITY 95 IMAGETYPE agg OUTPUTFORMAT NAME agg DRIVER AGG/PNG IMAGEMODE RGB END # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/ms4w/tmp/ms_tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/ms_tmp/' # WMS server settings METADATA 'ows_title' 'MH' 'ows_onlineresource' 'http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&' 'ows_srs' 'EPSG:4326 EPSG:900913' 'ows_enable_request' 'GetMap GetFeature GetFeatureInfo *' ##necessary "wms_feature_info_mime_type" "text/html" "wms_getfeatureinfo" "http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map&" "wms_featureinfoformat" "text/html" "wfs_abstract" "This text describes my WFS service." END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation TEMPLATE 'template.html' END LAYER NAME 'maps' TYPE POINT DUMP true TEMPLATE 'template.html' HEADER 'header.html' FOOTER 'footer.html' EXTENT -86.731680 24.422064 -76.149835 30.424575 CONNECTIONTYPE postgis CONNECTION "dbname='postgis' host=localhost port=5432 user='postgres' password='xxxxxx' sslmode=disable" DATA 'the_geom FROM "maps" USING UNIQUE id USING srid=4326' FILTER ( geometrytype("the_geom") IN ('POINT','MULTIPOINT') ) METADATA 'ows_title' 'maps' 'wfs_typename' 'maps' 'wfs_version' '1.0.0' 'wfs_connectiontimeout' '60' 'wfs_maxfeatures' '150' 'wfs_filter' 'GET' 'wms_include_items' 'all' 'wfs_featureid' 'the_geom' 'gml_include_items' 'all' END STATUS OFF TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'no_defs' END CLASS NAME 'maps' STYLE SYMBOL "circle" SIZE 7.0 OUTLINECOLOR 0 0 0 COLOR 170 211 227 END END END END Template.html -- [lrn][NAME][LAT][LON][ELEVATION][QUADNAME] header.html-- Layer: airports

footer.html --
 namelatitudelongitudeaddressdescription

If any finds any fault with my code or anything that should be added to get feature info then please let me know. Awaiting reply. With Regards, Neelima Emmani -------------- next part -------------- An HTML attachment was scrubbed... URL: From pereng at gmail.com Tue Apr 10 02:55:57 2012 From: pereng at gmail.com (=?ISO-8859-1?Q?Per_Engstr=F6m?=) Date: Tue, 10 Apr 2012 11:55:57 +0200 Subject: [mapserver-users] Extent in grouped layers Message-ID: Hello fellow MapServer Users! I've been working with MapServer for some time now and I'm starting to get a good grip of things. However I am currently facing a problem to which I can not find a sollution. What I need to do is to create a composite layer consisting of four sublayers and set the projected extent of the composite layer. Each sublayer gets an extent but the composite layer does not. Is this possible to do? And if so, how? I've tried to group the layers both with the GROUP tag and with the layer object metadata "wms_layer_group". Both methods does group the layers but, with neighter method the extent of the composite layer get set. With the later metod I am missing an complementing metadata: "wms_group_extent", which would work just like "wms_group_title", thus enabling setting the extent of the group!? I know it is possible to set the extent for the MAP object but this is not an option in my case - I need to solve this problem on a more granular level. Regards, Per -------------- next part -------------- An HTML attachment was scrubbed... URL: From remon.sadikni at zmaw.de Tue Apr 10 02:59:05 2012 From: remon.sadikni at zmaw.de (Remon Sadikni) Date: Tue, 10 Apr 2012 11:59:05 +0200 Subject: [mapserver-users] osgeo mapserver error In-Reply-To: <4F83F6B6.9080007@zmaw.de> References: <4F83F6B6.9080007@zmaw.de> Message-ID: <4F840469.5070806@zmaw.de> Thanks, it works again! Regards, Remon On 04/10/2012 11:00 AM, Remon Sadikni wrote: > Dear mapserver team, > > today the osgeo mapserver gives the following error message instead of a > map: > > msDrawMap(): Image handling error ... Unable to access file. > (/mapdata/vmap0/disp/ceasefire_v0sas_4) > > It is the result of this request from our Live Access Server: > > http://vmap0.tiles.osgeo.org/wms/vmap0?FORMAT=image%2Fpng&LAYERS=basic&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&SRS=EPSG%3A4326&BBOX=-180,-90,180,270&WIDTH=256&HEIGHT=256 > > > Thank you and best regards, > Remon -- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Dipl. Inf. Remon Sadikni Scientific Programmer University of Hamburg / KlimaCampus Hamburg Center for Integrated Climate System Analysis and Prediction - CliSAP Grindelberg 5 / D-20144 Hamburg / Germany phone: +49-40-42838-7581 email: remon.sadikni at zmaw.de +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ From kguardado at gmail.com Tue Apr 10 04:18:08 2012 From: kguardado at gmail.com (Karina Guardado) Date: Tue, 10 Apr 2012 05:18:08 -0600 Subject: [mapserver-users] labels problem Message-ID: Hi, I'm having problems with labels on my mapfile, when I use the parameter TYPE TRUETYPE then I can't see the map but when I erase this line I can see the map but never see the labels. I have checked the path to the fonset file and it is ok, also I have verified the .ttf file corresponding to the font exist. Any idea about this problem, I'm using mapserver 5.6.5 regards Karina Guardado El Salvador From fernando at globalgeo.com.br Tue Apr 10 05:11:39 2012 From: fernando at globalgeo.com.br (Fernando Norte) Date: Tue, 10 Apr 2012 09:11:39 -0300 Subject: [mapserver-users] labels problem In-Reply-To: References: Message-ID: Hi Karina, I need more information about your mapfile and font file to help you, try to paste the code here or use http://pastebin.com/. Try check if had any error in the mapfile, you can view this error just showing the map with mode=map or declare a error log file in the mapfile with: CONFIG "MS_ERRORFILE" "/path/to/file.log" Maybe you not specify the FONT, or another error in mapfile. Att, 2012/4/10 Karina Guardado > Hi, > > I'm having problems with labels on my mapfile, when I use the > parameter TYPE TRUETYPE then I can't see the map but when I erase this > line I can see the map but never see the labels. I have checked the > path to the fonset file and it is ok, also I have verified the .ttf > file corresponding to the font exist. Any idea about this problem, I'm > using mapserver 5.6.5 > > > regards > > Karina Guardado > El Salvador > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From kguardado at gmail.com Tue Apr 10 07:10:36 2012 From: kguardado at gmail.com (Karina Guardado) Date: Tue, 10 Apr 2012 08:10:36 -0600 Subject: [mapserver-users] labels problem In-Reply-To: References: Message-ID: Hi Fernando, Thank you very much for your reply , you know I found the problem and it was the .ttf file so I download another arial.ttf for example and then it worked fine. I have another question, is it possible that Mapserver have something like the Map tips of Arcgis? or is it related with other software like Openlayers for example? best regards, karina On Tue, Apr 10, 2012 at 6:11 AM, Fernando Norte wrote: > Hi Karina, > > I need more information about your mapfile and font file to help you, try > to paste the code here or use http://pastebin.com/. > Try check if had any error in the mapfile, you can view this error just > showing the map with mode=map or declare a error log file in the mapfile > with: CONFIG "MS_ERRORFILE" "/path/to/file.log" > > Maybe you not specify the FONT, or another error in mapfile. > > Att, > > > > > 2012/4/10 Karina Guardado > >> Hi, >> >> I'm having problems with labels on my mapfile, when I use the >> parameter TYPE TRUETYPE then I can't see the map but when I erase this >> line I can see the map but never see the labels. I have checked the >> path to the fonset file and it is ok, also I have verified the .ttf >> file corresponding to the font exist. Any idea about this problem, I'm >> using mapserver 5.6.5 >> >> >> regards >> >> Karina Guardado >> El Salvador >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From fernando at globalgeo.com.br Tue Apr 10 07:24:17 2012 From: fernando at globalgeo.com.br (Fernando Norte) Date: Tue, 10 Apr 2012 11:24:17 -0300 Subject: [mapserver-users] labels problem In-Reply-To: References: Message-ID: Hi Karina, This feature of create tips its more concearn to the interface, like OpenLayers. The MapServer can be used as WMS to provide the data to this 'tips', but the OpenLayers (or even jQuery) will create the tip and control the mouse event to open it. This is a little bit of complex for non programers, because need JavaScript skills to create it. Att, 2012/4/10 Karina Guardado > Hi Fernando, > > Thank you very much for your reply , you know I found the problem and it > was the .ttf file so I download another arial.ttf for example and then it > worked fine. > > I have another question, is it possible that Mapserver have something > like the Map tips of Arcgis? or is it related with other software like > Openlayers for example? > > best regards, > > karina > > > On Tue, Apr 10, 2012 at 6:11 AM, Fernando Norte > wrote: > >> Hi Karina, >> >> I need more information about your mapfile and font file to help you, try >> to paste the code here or use http://pastebin.com/. >> Try check if had any error in the mapfile, you can view this error just >> showing the map with mode=map or declare a error log file in the mapfile >> with: CONFIG "MS_ERRORFILE" "/path/to/file.log" >> >> Maybe you not specify the FONT, or another error in mapfile. >> >> Att, >> >> >> >> >> 2012/4/10 Karina Guardado >> >>> Hi, >>> >>> I'm having problems with labels on my mapfile, when I use the >>> parameter TYPE TRUETYPE then I can't see the map but when I erase this >>> line I can see the map but never see the labels. I have checked the >>> path to the fonset file and it is ok, also I have verified the .ttf >>> file corresponding to the font exist. Any idea about this problem, I'm >>> using mapserver 5.6.5 >>> >>> >>> regards >>> >>> Karina Guardado >>> El Salvador >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> >> >> > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From kguardado at gmail.com Tue Apr 10 07:26:27 2012 From: kguardado at gmail.com (Karina Guardado) Date: Tue, 10 Apr 2012 08:26:27 -0600 Subject: [mapserver-users] labels problem In-Reply-To: References: Message-ID: thank you very much Fernando and now it is clear for me. regards, On Tue, Apr 10, 2012 at 8:24 AM, Fernando Norte wrote: > Hi Karina, > > This feature of create tips its more concearn to the interface, like > OpenLayers. The MapServer can be used as WMS to provide the data to this > 'tips', but the OpenLayers (or even jQuery) will create the tip and control > the mouse event to open it. This is a little bit of complex for non > programers, because need JavaScript skills to create it. > > Att, > > > > > 2012/4/10 Karina Guardado > >> Hi Fernando, >> >> Thank you very much for your reply , you know I found the problem and it >> was the .ttf file so I download another arial.ttf for example and then it >> worked fine. >> >> I have another question, is it possible that Mapserver have something >> like the Map tips of Arcgis? or is it related with other software like >> Openlayers for example? >> >> best regards, >> >> karina >> >> >> On Tue, Apr 10, 2012 at 6:11 AM, Fernando Norte < >> fernando at globalgeo.com.br> wrote: >> >>> Hi Karina, >>> >>> I need more information about your mapfile and font file to help you, >>> try to paste the code here or use http://pastebin.com/. >>> Try check if had any error in the mapfile, you can view this error just >>> showing the map with mode=map or declare a error log file in the mapfile >>> with: CONFIG "MS_ERRORFILE" "/path/to/file.log" >>> >>> Maybe you not specify the FONT, or another error in mapfile. >>> >>> Att, >>> >>> >>> >>> >>> 2012/4/10 Karina Guardado >>> >>>> Hi, >>>> >>>> I'm having problems with labels on my mapfile, when I use the >>>> parameter TYPE TRUETYPE then I can't see the map but when I erase this >>>> line I can see the map but never see the labels. I have checked the >>>> path to the fonset file and it is ok, also I have verified the .ttf >>>> file corresponding to the font exist. Any idea about this problem, I'm >>>> using mapserver 5.6.5 >>>> >>>> >>>> regards >>>> >>>> Karina Guardado >>>> El Salvador >>>> _______________________________________________ >>>> mapserver-users mailing list >>>> mapserver-users at lists.osgeo.org >>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>>> >>> >>> >> >> >> >> >> >> >> > -- M.Sc. Karina Guardado Celular: (503) 7115 2898 -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Tue Apr 10 13:59:51 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Tue, 10 Apr 2012 20:59:51 +0000 Subject: [mapserver-users] Help Please Message-ID: Hi All I created a map by using a map file in OpenLayers and I am trying to query some features but I couldn't make it. Also, do I have to set something in map file to query a feature in Openlayers? I am using these codes but no result. Can someone help me what is my mistake? Codes are below; Thanks map.events.register('click', map, function (e) { OpenLayers.Util.getElement('nodeList').innerHTML = "Loading... please wait..."; var url = wms.getFullRequestString({ REQUEST: "GetFeatureInfo", EXCEPTIONS: "application/vnd.ogc.se_xml", BBOX: wms.map.getExtent().toBBOX(), X: e.xy.x, Y: e.xy.y, INFO_FORMAT: 'text/html', QUERY_LAYERS: wms.params.LAYERS, WIDTH: wms.map.size.w, HEIGHT: wms.map.size.h}); OpenLayers.loadURL(url, '', this, setHTML); OpenLayers.Event.stop(e); }); function setHTML(response) { OpenLayers.Util.getElement('nodeList').innerHTML = response.responseText; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From ozgurarslan81 at hotmail.com Tue Apr 10 22:50:31 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Wed, 11 Apr 2012 05:50:31 +0000 Subject: [mapserver-users] Help Please Message-ID: Hi Everyone, I am trying query some features by usin openlayers and when I click on features it gives me this error; msLoadMap(): Regular expression error. MS_DEFAULT_MAPFILE_PATTERN validation failed. msEvalRegex(): Regular expression error. String failed expression test. Does someone know how can I fix the problem? Regards -------------- next part -------------- An HTML attachment was scrubbed... URL: From fernando at globalgeo.com.br Wed Apr 11 06:42:31 2012 From: fernando at globalgeo.com.br (Fernando Norte) Date: Wed, 11 Apr 2012 10:42:31 -0300 Subject: [mapserver-users] Help Please In-Reply-To: References: Message-ID: Hi Ozz, This error is about an EXPRESSION that you used in the layer of a mapFile, check this out. Att, 2012/4/11 ?zg?r Arslan > Hi Everyone, > > I am trying query some features by usin openlayers and when I click on > features it gives me this error; > > msLoadMap(): Regular expression error. MS_DEFAULT_MAPFILE_PATTERN > validation failed. msEvalRegex(): Regular expression error. String failed > expression test. > > > Does someone know how can I fix the problem? > > Regards > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Thomas.Joseph at awtwater.com Wed Apr 11 21:20:54 2012 From: Thomas.Joseph at awtwater.com (Thomas Joseph) Date: Thu, 12 Apr 2012 16:20:54 +1200 Subject: [mapserver-users] Turn off anti-alias Mapserver 6.0 Message-ID: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> We have recently upgraded from Mapserver 5.7 to 6.0 and although the AGG anti-alias lines look great the output image size has increased significantly from the previous rendering without anti-alias. I was just wondering if there is a way to turn off the anti-alias for polyline rendering in Mapserver 6.0. From the documentation it appeared that the previous GD driver did not include anti-alias by default. We have attempted to switch the outputformat from the new default AGG to the previous GD driver using the outputformat directive in the map file as shown below. This changed the image size slightly suggesting that mapserver was using a different driver to render, however the lines were still rendered with anti-alias on and the image was still relatively large compared to previous mapserver verison. OUTPUTFORMAT NAME "GDpng" DRIVER GD/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" END Previously in Mapserver 5.7 we did not specify an outputformat we simply used IMAGETYPE PNG24 and the output was generated without anti-alias. Any suggestions would be greatly appreciated. If you need additional information let me know. tom -------------------------------------------------- THIS EMAIL IS CONFIDENTIAL. Its use or disclosure by any person other than the addressee is unauthorised. Anyone other than the intended recipient must not rely on the content of this email or any attachment to it. The sender cannot guarantee that this email or any attachment to it is free of computer viruses or other conditions which may damage or interfere with other computer systems. -------------------------------------------------- -------------- next part -------------- An HTML attachment was scrubbed... URL: From peter.hopfgartner at r3-gis.com Wed Apr 11 23:33:07 2012 From: peter.hopfgartner at r3-gis.com (Peter Hopfgartner) Date: Thu, 12 Apr 2012 08:33:07 +0200 Subject: [mapserver-users] Turn off anti-alias Mapserver 6.0 In-Reply-To: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> References: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> Message-ID: <4F867723.1080904@r3-gis.com> Hi Thomas You could try to reduce the image size using 8bit PNGs, see the 3rd output format in http://mapserver.org/mapfile/outputformat.html. Peter On 04/12/2012 06:20 AM, Thomas Joseph wrote: > > We have recently upgraded from Mapserver 5.7 to 6.0 and although the > AGG anti-alias lines look great the output image size has increased > significantly from the previous rendering without anti-alias. I was > just wondering if there is a way to turn off the anti-alias for > polyline rendering in Mapserver 6.0. From the documentation it > appeared that the previous GD driver did not include anti-alias by > default. We have attempted to switch the outputformat from the new > default AGG to the previous GD driver using the outputformat directive > in the map file as shown below. This changed the image size slightly > suggesting that mapserver was using a different driver to render, > however the lines were still rendered with anti-alias on and the image > was still relatively large compared to previous mapserver verison. > > OUTPUTFORMAT > > NAME "GDpng" > > DRIVER GD/PNG > > MIMETYPE "image/png" > > IMAGEMODE RGB > > EXTENSION "png" > > END > > Previously in Mapserver 5.7 we did not specify an outputformat we > simply used IMAGETYPE PNG24 and the output was generated without > anti-alias. Any suggestions would be greatly appreciated. If you > need additional information let me know. > > tom > > ------------------------------------------------------------------------ > > THIS EMAIL IS CONFIDENTIAL. Its use or disclosure by any person other > than the addressee is unauthorised. Anyone other than the intended > recipient must not rely on the content of this email or any attachment > to it. The sender cannot guarantee that this email or any attachment > to it is free of computer viruses or other conditions which may damage > or interfere with other computer systems. > > ------------------------------------------------------------------------ > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -- Peter Hopfgartner http://www.r3-gis.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.bonfort at gmail.com Thu Apr 12 00:59:18 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Thu, 12 Apr 2012 09:59:18 +0200 Subject: [mapserver-users] Turn off anti-alias Mapserver 6.0 In-Reply-To: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> References: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> Message-ID: On Thu, Apr 12, 2012 at 06:20, Thomas Joseph wrote: > We have recently upgraded from Mapserver 5.7 to 6.0 and although the AGG > anti-alias lines look great the output image size has increased > significantly from the previous rendering without anti-alias.? I was just > wondering if? there is a way to turn off the anti-alias for polyline > rendering in Mapserver 6.0.? From the documentation it appeared that the > previous GD driver did not include anti-alias by default.?? We have > attempted to switch the outputformat from the new default AGG to the > previous GD driver using the outputformat directive in the map file as shown > below.? This changed the image size slightly suggesting that mapserver was > using a different driver to render, however the lines were still rendered > with anti-alias on and the image was still relatively large compared to > previous mapserver verison. > > > > OUTPUTFORMAT > > ? NAME "GDpng" > > ? DRIVER GD/PNG > > ? MIMETYPE "image/png" > > ? IMAGEMODE RGB GD only supports PC256. If you set imagemode to RGB as here, mapserver will switch back to AGG. -- thomas > > ? EXTENSION "png" > > END > > > > Previously in Mapserver 5.7 we did not specify an outputformat we simply > used IMAGETYPE PNG24 and the output was generated without anti-alias.? Any > suggestions would be greatly appreciated.? If you need additional > information let me know. > > > > tom > > > > > > > > > > > > > > > > > > ________________________________ > > THIS EMAIL IS CONFIDENTIAL.? Its use or disclosure by any person other than > the addressee is unauthorised.? Anyone other than the intended recipient > must not rely on the content of this email or any attachment to it.? The > sender cannot guarantee that this email or any attachment to it is free of > computer viruses or other conditions which may damage or interfere with > other computer systems. > > ________________________________ > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From Thomas.Joseph at awtwater.com Thu Apr 12 01:24:55 2012 From: Thomas.Joseph at awtwater.com (Thomas Joseph) Date: Thu, 12 Apr 2012 20:24:55 +1200 Subject: [mapserver-users] Turn off anti-alias Mapserver 6.0 In-Reply-To: References: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> Message-ID: <65BEB16FA7472A47ADFC80A42BF04FE801ADC201@awtsbs01> Hi Thanks for the quick response I also tried PC256 as discussed in the outputformat instruction sheet. Although the image did look similar to the results from 5.7 and the size was much smaller it did not render transparent polygons correctly. I may have missed something else here. Is there a way to turn off anti-aliasing with the AGG driver ? Thanks again ? -----Original Message----- From: thomas bonfort [mailto:thomas.bonfort at gmail.com] Sent: Thursday, 12 April 2012 7:59 p.m. To: Thomas Joseph Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Turn off anti-alias Mapserver 6.0 On Thu, Apr 12, 2012 at 06:20, Thomas Joseph wrote: > We have recently upgraded from Mapserver 5.7 to 6.0 and although the > AGG anti-alias lines look great the output image size has increased > significantly from the previous rendering without anti-alias.? I was > just wondering if? there is a way to turn off the anti-alias for > polyline rendering in Mapserver 6.0.? From the documentation it > appeared that the previous GD driver did not include anti-alias by > default.?? We have attempted to switch the outputformat from the new > default AGG to the previous GD driver using the outputformat directive > in the map file as shown below.? This changed the image size slightly > suggesting that mapserver was using a different driver to render, > however the lines were still rendered with anti-alias on and the image > was still relatively large compared to previous mapserver verison. > > > > OUTPUTFORMAT > > ? NAME "GDpng" > > ? DRIVER GD/PNG > > ? MIMETYPE "image/png" > > ? IMAGEMODE RGB GD only supports PC256. If you set imagemode to RGB as here, mapserver will switch back to AGG. -- thomas > > ? EXTENSION "png" > > END > > > > Previously in Mapserver 5.7 we did not specify an outputformat we > simply used IMAGETYPE PNG24 and the output was generated without > anti-alias.? Any suggestions would be greatly appreciated.? If you > need additional information let me know. > > > > tom > > > > > > > > > > > > > > > > > > ________________________________ > > THIS EMAIL IS CONFIDENTIAL.? Its use or disclosure by any person other > than the addressee is unauthorised.? Anyone other than the intended > recipient must not rely on the content of this email or any attachment > to it.? The sender cannot guarantee that this email or any attachment > to it is free of computer viruses or other conditions which may damage > or interfere with other computer systems. > > ________________________________ > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From thomas.bonfort at gmail.com Thu Apr 12 01:44:40 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Thu, 12 Apr 2012 10:44:40 +0200 Subject: [mapserver-users] Turn off anti-alias Mapserver 6.0 In-Reply-To: <65BEB16FA7472A47ADFC80A42BF04FE801ADC201@awtsbs01> References: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> <65BEB16FA7472A47ADFC80A42BF04FE801ADC201@awtsbs01> Message-ID: On Thu, Apr 12, 2012 at 10:24, Thomas Joseph wrote: > Hi > > Thanks for the quick response > > I also tried PC256 as discussed in the outputformat instruction sheet. ?Although the image did look similar to the results from 5.7 and the size was much smaller it did not render transparent polygons correctly. > > I may have missed something else here. ?Is there a way to turn off anti-aliasing with the AGG driver ? Currently no. It could be implemented for simple (1 pixel wide) lines and polygons, contact me if you would like a quote. regards, thomas > > Thanks again > > > -----Original Message----- > From: thomas bonfort [mailto:thomas.bonfort at gmail.com] > Sent: Thursday, 12 April 2012 7:59 p.m. > To: Thomas Joseph > Cc: mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] Turn off anti-alias Mapserver 6.0 > > On Thu, Apr 12, 2012 at 06:20, Thomas Joseph wrote: >> We have recently upgraded from Mapserver 5.7 to 6.0 and although the >> AGG anti-alias lines look great the output image size has increased >> significantly from the previous rendering without anti-alias.? I was >> just wondering if? there is a way to turn off the anti-alias for >> polyline rendering in Mapserver 6.0.? From the documentation it >> appeared that the previous GD driver did not include anti-alias by >> default.?? We have attempted to switch the outputformat from the new >> default AGG to the previous GD driver using the outputformat directive >> in the map file as shown below.? This changed the image size slightly >> suggesting that mapserver was using a different driver to render, >> however the lines were still rendered with anti-alias on and the image >> was still relatively large compared to previous mapserver verison. >> >> >> >> OUTPUTFORMAT >> >> ? NAME "GDpng" >> >> ? DRIVER GD/PNG >> >> ? MIMETYPE "image/png" >> >> ? IMAGEMODE RGB > GD only supports PC256. If you set imagemode to RGB as here, mapserver will switch back to AGG. > > -- > thomas > >> >> ? EXTENSION "png" >> >> END >> >> >> >> Previously in Mapserver 5.7 we did not specify an outputformat we >> simply used IMAGETYPE PNG24 and the output was generated without >> anti-alias.? Any suggestions would be greatly appreciated.? If you >> need additional information let me know. >> >> >> >> tom >> >> >> >> >> >> >> >> >> >> >> >> >> >> >> >> >> >> ________________________________ >> >> THIS EMAIL IS CONFIDENTIAL.? Its use or disclosure by any person other >> than the addressee is unauthorised.? Anyone other than the intended >> recipient must not rely on the content of this email or any attachment >> to it.? The sender cannot guarantee that this email or any attachment >> to it is free of computer viruses or other conditions which may damage >> or interfere with other computer systems. >> >> ________________________________ >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > From juanma.mr at gmail.com Thu Apr 12 02:13:20 2012 From: juanma.mr at gmail.com (Juanma M. R.) Date: Thu, 12 Apr 2012 11:13:20 +0200 Subject: [mapserver-users] pointObj->project behaviour differences from 4.10 to 5.6 versions Message-ID: Dear list, I have a webgis application working with different CRS all over the world. I have realized that the behaviour from version 4.10 of the function pointObj->project differs from the one of version 5.6 from Mapserver. For example, I try to convert (-116,-15) in 4326 and in mapscript from version 4.10 it returns (-26158630.407638,-25040425.679281) when passing to 32630. On the other hand, in version 5.6 of mapscript it returns the original coordinates without transforming them. Is this intended or am I doing something wrong? Which is the intended behaviour of project function in MapServer 5.6? Best regards, -- Juan Manuel Moreno Rivera. University of Castilla-La Mancha Albacete, Spain -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Thu Apr 12 04:54:11 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Thu, 12 Apr 2012 07:54:11 -0400 Subject: [mapserver-users] Turn off anti-alias Mapserver 6.0 In-Reply-To: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> References: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> Message-ID: <4F86C263.7090409@swoodbridge.com> Tom, Try this output definition: OUTPUTFORMAT NAME "agg_qn" DRIVER "AGG/PNG" EXTENSION "png" MIMETYPE "image/png" IMAGEMODE RGB FORMATOPTION "INTERLACE=false" FORMATOPTION "QUANTIZE_NEW=ON" FORMATOPTION "QUANTIZE_FORCE=ON" FORMATOPTION "QUANTIZE_DITHER=OFF" FORMATOPTION "QUANTIZE_COLORS=256" #TRANSPARENT ON #FORMATOPTION "TRANSPARENT=ON" END -Steve W On 4/12/2012 12:20 AM, Thomas Joseph wrote: > We have recently upgraded from Mapserver 5.7 to 6.0 and although the AGG > anti-alias lines look great the output image size has increased > significantly from the previous rendering without anti-alias. I was just > wondering if there is a way to turn off the anti-alias for polyline > rendering in Mapserver 6.0. From the documentation it appeared that the > previous GD driver did not include anti-alias by default. We have > attempted to switch the outputformat from the new default AGG to the > previous GD driver using the outputformat directive in the map file as > shown below. This changed the image size slightly suggesting that > mapserver was using a different driver to render, however the lines were > still rendered with anti-alias on and the image was still relatively > large compared to previous mapserver verison. > > OUTPUTFORMAT > > NAME "GDpng" > > DRIVER GD/PNG > > MIMETYPE "image/png" > > IMAGEMODE RGB > > EXTENSION "png" > > END > > Previously in Mapserver 5.7 we did not specify an outputformat we simply > used IMAGETYPE PNG24 and the output was generated without anti-alias. > Any suggestions would be greatly appreciated. If you need additional > information let me know. > > tom > > THIS EMAIL IS CONFIDENTIAL. Its use or disclosure by any person other > than the addressee is unauthorised. Anyone other than the intended > recipient must not rely on the content of this email or any attachment > to it. The sender cannot guarantee that this email or any attachment to > it is free of computer viruses or other conditions which may damage or > interfere with other computer systems. > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From Thomas.Joseph at awtwater.com Fri Apr 13 18:06:26 2012 From: Thomas.Joseph at awtwater.com (tom) Date: Fri, 13 Apr 2012 18:06:26 -0700 (PDT) Subject: [mapserver-users] Re: Turn off anti-alias Mapserver 6.0 In-Reply-To: <4F86C263.7090409@swoodbridge.com> References: <65BEB16FA7472A47ADFC80A42BF04FE801ADC1BA@awtsbs01> <4F86C263.7090409@swoodbridge.com> Message-ID: <1334365586684-4880402.post@n6.nabble.com> Steve, That certainly helps. What is the difference (if any) between FORMATOPTION "QUANTIZE_COLORS=256" and the outputformat AGG/PNG8. I am just a little concerned about the reduced color palette, however it may not be an issue for us I will just have to do some experimenting. I may be mistaken but it seems like in version 5.7 we used to be able get a 24bit PNG with no anti-aliasing and the image size was reasonable. From my research it seems that 5.7 used the GD driver by default but GD with Imagetype PC256 is certainly not rendering the same as 5.7 default. Tom Stephen Woodbridge wrote > > Tom, > > Try this output definition: > > OUTPUTFORMAT > NAME "agg_qn" > DRIVER "AGG/PNG" > EXTENSION "png" > MIMETYPE "image/png" > IMAGEMODE RGB > FORMATOPTION "INTERLACE=false" > FORMATOPTION "QUANTIZE_NEW=ON" > FORMATOPTION "QUANTIZE_FORCE=ON" > FORMATOPTION "QUANTIZE_DITHER=OFF" > FORMATOPTION "QUANTIZE_COLORS=256" > #TRANSPARENT ON > #FORMATOPTION "TRANSPARENT=ON" > END > > -Steve W > > On 4/12/2012 12:20 AM, Thomas Joseph wrote: >> We have recently upgraded from Mapserver 5.7 to 6.0 and although the AGG >> anti-alias lines look great the output image size has increased >> significantly from the previous rendering without anti-alias. I was just >> wondering if there is a way to turn off the anti-alias for polyline >> rendering in Mapserver 6.0. From the documentation it appeared that the >> previous GD driver did not include anti-alias by default. We have >> attempted to switch the outputformat from the new default AGG to the >> previous GD driver using the outputformat directive in the map file as >> shown below. This changed the image size slightly suggesting that >> mapserver was using a different driver to render, however the lines were >> still rendered with anti-alias on and the image was still relatively >> large compared to previous mapserver verison. >> >> OUTPUTFORMAT >> >> NAME "GDpng" >> >> DRIVER GD/PNG >> >> MIMETYPE "image/png" >> >> IMAGEMODE RGB >> >> EXTENSION "png" >> >> END >> >> Previously in Mapserver 5.7 we did not specify an outputformat we simply >> used IMAGETYPE PNG24 and the output was generated without anti-alias. >> Any suggestions would be greatly appreciated. If you need additional >> information let me know. >> >> tom >> >> THIS EMAIL IS CONFIDENTIAL. Its use or disclosure by any person other >> than the addressee is unauthorised. Anyone other than the intended >> recipient must not rely on the content of this email or any attachment >> to it. The sender cannot guarantee that this email or any attachment to >> it is free of computer viruses or other conditions which may damage or >> interfere with other computer systems. >> >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at .osgeo >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > _______________________________________________ > mapserver-users mailing list > mapserver-users at .osgeo > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Turn-off-anti-alias-Mapserver-6-0-tp4842613p4880402.html Sent from the Mapserver - User mailing list archive at Nabble.com. From ozgurarslan81 at hotmail.com Mon Apr 16 01:21:56 2012 From: ozgurarslan81 at hotmail.com (=?iso-8859-1?B?1npn/HIgQXJzbGFu?=) Date: Mon, 16 Apr 2012 08:21:56 +0000 Subject: [mapserver-users] HI EVERYONE Message-ID: Hi everyone , I have a problem with this three layers. The problem is when I run the layers Copper and silver are only giving the gold locations and information. I couldn't figure out the problem. Can someone please help me about issue? Also do my class items correct? Maybe class items are the problems. Help please! Regards, Ozz LAYER NAME '2011_GOLD' TYPE POINT DUMP false EXTENT -1247585.223949 211744.209812 2410997.472876 1929711.291341 DATA '../../../wwwroot/test/Data/2011.shp' METADATA 'ows_title' 'MDI_2011' END HEADER "2011_GOLD_header.html" FOOTER "2011_GOLD_footer.html" STATUS ON TRANSPARENCY 100 PROJECTION "init=epsg:1000001" END CLASSITEM 'P_COMMOD' CLASSITEM 'STATUS' TOLERANCE 5 TOLERANCEUNITS PIXELS CLASS NAME "GOLD" EXPRESSION "GOLD" EXPRESSION "PRODUCING MINE" TEMPLATE "2011_GOLD_query.html" STYLE SYMBOL "yellow_MarkerG" SIZE 22 END END CLASS NAME "GOLD" EXPRESSION "GOLD" EXPRESSION "OCCURRENCE" MAXSCALE 2500000 TEMPLATE "2011_GOLD_query.html" STYLE SYMBOL "pink_MarkerG" SIZE 22 END END CLASS NAME "GOLD" EXPRESSION "GOLD" EXPRESSION "PROSPECT" MAXSCALE 2000000 TEMPLATE "2011_GOLD_query.html" STYLE SYMBOL "blue_MarkerG" SIZE 22 END END CLASS NAME "GOLD" EXPRESSION "GOLD" EXPRESSION "DEVELOPED PROSPECT WITH RESERVES" MAXSCALE 1000000 TEMPLATE "2011_GOLD_query.html" STYLE SYMBOL "darkgreen_MarkerG" SIZE 22 END END CLASS NAME "GOLD" EXPRESSION "GOLD" EXPRESSION "DISCRETIONARY OCCURRENCE" MAXSCALE 1000000 TEMPLATE "2011_GOLD_query.html" STYLE SYMBOL "darkgreen_MarkerG" SIZE 22 END END CLASS NAME "GOLD" EXPRESSION "GOLD" EXPRESSION "PAST PRODUCING MINE WITH RESERVES" MAXSCALE 1000000 TEMPLATE "2011_GOLD_query.html" STYLE SYMBOL "darkgreen_MarkerG" SIZE 22 END END END LAYER NAME '2011_SILVER' TYPE POINT DUMP false EXTENT -1247585.223949 211744.209812 2410997.472876 1929711.291341 DATA '../../../wwwroot/test/Data/2011.shp' METADATA 'ows_title' 'MDI_2011' END STATUS ON TRANSPARENCY 100 PROJECTION "init=epsg:1000001" END CLASSITEM 'P_COMMOD' CLASSITEM 'STATUS' HEADER "2011_SILVER_header.html" FOOTER "2011_SILVER_footer.html" TOLERANCE 5 TOLERANCEUNITS PIXELS CLASS NAME "SILVER" EXPRESSION "SILVER" EXPRESSION "PRODUCING MINE" TEMPLATE "2011_SILVER_query.html" STYLE SYMBOL "paleblue_MarkerS" SIZE 22 END END CLASS NAME "SILVER" EXPRESSION "SILVER" EXPRESSION "OCCURRENCE" MAXSCALE 2500000 TEMPLATE "2011_SILVER_query.html" STYLE SYMBOL "darkgreen_MarkerS" SIZE 22 END END CLASS NAME "SILVER" EXPRESSION "SILVER" EXPRESSION "PROSPECT" MAXSCALE 2000000 TEMPLATE "2011_SILVER_query.html" STYLE SYMBOL "blue_MarkerS" SIZE 22 END END CLASS NAME "SILVER" EXPRESSION "SILVER" EXPRESSION "DEVELOPED PROSPECT WITH RESERVES" MAXSCALE 1000000 TEMPLATE "2011_SILVER_query.html" STYLE SYMBOL "pink_MarkerS" SIZE 22 END END CLASS NAME "SILVER" EXPRESSION "SILVER" EXPRESSION "DISCRETIONARY OCCURRENCE" MAXSCALE 1000000 TEMPLATE "2011_SILVER_query.html" STYLE SYMBOL "pink_MarkerS" SIZE 22 END END CLASS NAME "SILVER" EXPRESSION "SILVER" EXPRESSION "PAST PRODUCING MINE WITH RESERVES" MAXSCALE 1000000 TEMPLATE "2011_SILVER_query.html" STYLE SYMBOL "pink_MarkerS" SIZE 22 END END END LAYER NAME '2011_COPPER' TYPE POINT DUMP false EXTENT -1247585.223949 211744.209812 2410997.472876 1929711.291341 DATA '../../../wwwroot/test/Data/2011.shp' METADATA 'ows_title' 'MDI_2011' END STATUS ON TRANSPARENCY 100 PROJECTION "init=epsg:1000001" END CLASSITEM 'P_COMMOD' CLASSITEM 'STATUS' HEADER "2011_COPPER_header.html" FOOTER "2011_COPPER_footer.html" TOLERANCE 5 TOLERANCEUNITS PIXELS CLASS NAME "COPPER" EXPRESSION "COPPER" EXPRESSION "PRODUCING MINE" TEMPLATE "2011_COPPER_query.html" STYLE SYMBOL "orange_MarkerC" SIZE 22 END END CLASS NAME "COPPER" EXPRESSION "COPPER" EXPRESSION "OCCURRENCE" MAXSCALE 2500000 TEMPLATE "2011_COPPER_query.html" STYLE SYMBOL "darkgreen_MarkerC" SIZE 22 END END CLASS NAME "COPPER" EXPRESSION "COPPER" EXPRESSION "PROSPECT" MAXSCALE 2000000 TEMPLATE "2011_COPPER_query.html" STYLE SYMBOL "blue_MarkerC" SIZE 22 END END CLASS NAME "COPPER" EXPRESSION "COPPER" EXPRESSION "DEVELOPED PROSPECT WITH RESERVES" MAXSCALE 1000000 TEMPLATE "2011_COPPER_query.html" STYLE SYMBOL "pink_MarkerC" SIZE 22 END END CLASS NAME "COPPER" EXPRESSION "COPPER" EXPRESSION "DISCRETIONARY OCCURRENCE" MAXSCALE 1000000 TEMPLATE "2011_COPPER_query.html" STYLE SYMBOL "pink_MarkerC" SIZE 22 END END CLASS NAME "COPPER" EXPRESSION "COPPER" EXPRESSION "PAST PRODUCING MINE WITH RESERVES" MAXSCALE 1000000 TEMPLATE "2011_COPPER_query.html" STYLE SYMBOL "pink_MarkerC" SIZE 22 END END END -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Mon Apr 16 09:22:59 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Mon, 16 Apr 2012 11:22:59 -0500 Subject: [mapserver-users] Passing a mapfile via CGI Message-ID: <4F8C0113020000A8000353FC@heckle> All, Did anything ever develop from this idea? I need to generate a variable length list of layers pro grammatically. I'm not finding anything from a quick search of things related to passing a MAPFILE via the CGI call. I want to be able to generate a MAPFILE, or chunks of it, on the fly. A possible solution (maybe scary security wise) would be to use a param like "INCLUDE_=", to pass in MAP fragments to an existing MAPFILE. I need to essentially add layers. Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be to have MapServer build it's own MAPFILE as a TEMPLATE output, but I'm not coming up with a way immediately of passing the resulting MAPFILE to Mapserver in the end. bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Mon Apr 16 09:41:21 2012 From: bfraser at geoanalytic.com (Brent Fraser) Date: Mon, 16 Apr 2012 10:41:21 -0600 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C0113020000A8000353FC@heckle> References: <4F8C0113020000A8000353FC@heckle> Message-ID: <4F8C4BB1.5000108@geoanalytic.com> Bob, What kinds of things are you trying to do with layers? Are the layers vectors? Maybe there's a different way... I'm in the midst of an implementation where the vectors are held in PostGIS in three tables (point, line and polygon) and joined to a "feature definition" table (to supply rendering values). I use one map file with three layers (point, line, polygon) and pass a FILTER variable to get my different layers which are then rendered. Here's a snippet from the polygon layer: CLASS STYLE # Polygon Fill SYMBOL [polyfill_symbol] COLOR [polyfill_fillcolor] ANGLE [polyfill_angle] SIZE [polyfill_hatchgap] # e.g Hatching gap WIDTH 1 # [polyfill_hatchthick] # Hatching line thickness (column binding doesn't seem to work) # OPACITY 50 # [attribute] # warning: there is no OPACITY for LABEL so don't bother. END STYLE # Polygon Outline SYMBOL [geom_symbol] OUTLINECOLOR [geom_outcolor] SIZE [geom_width] # for "simple" (?) symbols WIDTH [geom_width] # for complex symbols END # Style TEXT ([gid]) LABEL TYPE TRUETYPE FONT [label_font] ANTIALIAS TRUE COLOR [label_fillcolor] OUTLINECOLOR [label_outcolor] BUFFER 1 POSITION cc # [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] PARTIALS TRUE SIZE [label_height] END # LABEL END # class While this method is suitable for rendering, it will be a problem if you want store variables for use in an identify operation (or maybe not; I wonder if a template name can be bound to a database column...) Best Regards, Brent Fraser On 4/16/2012 10:22 AM, Bob Basques wrote: > > All, > > > Did anything ever develop from this idea? I need to generate a > variable length list of layers pro grammatically. > > > I'm not finding anything from a quick search of things related to > passing a MAPFILE via the CGI call. I want to be able to generate a > MAPFILE, or chunks of it, on the fly. A possible solution (maybe > scary security wise) would be to use a param like "INCLUDE_=", > to pass in MAP fragments to an existing MAPFILE. I need to > essentially add layers. > > > Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be > to have MapServer build it's own MAPFILE as a TEMPLATE output, but I'm > not coming up with a way immediately of passing the resulting MAPFILE > to Mapserver in the end. > > > bobb > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Mon Apr 16 10:05:52 2012 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 16 Apr 2012 14:05:52 -0300 Subject: [mapserver-users] HI EVERYONE In-Reply-To: References: Message-ID: <4F8C5170.6010006@gatewaygeomatics.com> On 12-04-16 5:21 AM, ?zg?r Arslan wrote: > Hi everyone , > > I have a problem with this three layers. The problem is when I run the > layers Copper and silver are only giving the gold locations and > information. I couldn't figure out the problem. Can someone please help > me about issue? Also do my class items correct? Maybe class items are > the problems. Help please! > Hello, I took a quick glance at your example LAYERS, and I see several bad things (multiple CLASSITEM declarations for a single layer, multiple EXPRESSION lines for a single class); you might want to review the MapServer expressions document (http://www.mapserver.org/mapfile/expressions.html). In general, if I was in your shoes, I might use the LAYER parameter FILTER (see "filter" parameter at http://www.mapserver.org/mapfile/layer.html) to handle your gold/silver/copper filtering, and then use a single CLASSITEM and EXPRESSION in your class for that other filtering. -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ From Steve.Lime at state.mn.us Mon Apr 16 10:58:04 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Mon, 16 Apr 2012 17:58:04 +0000 Subject: [mapserver-users] pointObj->project behaviour differences from 4.10 to 5.6 versions In-Reply-To: References: Message-ID: The transformation is done in place, I've not had problems with it. What language? Can you post a code snippet? From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Juanma M. R. Sent: Thursday, April 12, 2012 4:13 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] pointObj->project behaviour differences from 4.10 to 5.6 versions Dear list, I have a webgis application working with different CRS all over the world. I have realized that the behaviour from version 4.10 of the function pointObj->project differs from the one of version 5.6 from Mapserver. For example, I try to convert (-116,-15) in 4326 and in mapscript from version 4.10 it returns (-26158630.407638,-25040425.679281) when passing to 32630. On the other hand, in version 5.6 of mapscript it returns the original coordinates without transforming them. Is this intended or am I doing something wrong? Which is the intended behaviour of project function in MapServer 5.6? Best regards, -- Juan Manuel Moreno Rivera. University of Castilla-La Mancha Albacete, Spain -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Mon Apr 16 12:07:12 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Mon, 16 Apr 2012 14:07:12 -0500 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C4BB1.5000108@geoanalytic.com> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> Message-ID: <4F8C2790020000A80003541D@heckle> Hmm, interesting apporach, reminds me of my ealier days with Oracle (before Oracle Spatial, where each feature type needed it's own table structure . . . Have to do some more thinking on this one. I'm trying to render a predefined list of layers (from the user) of a set of GPS trails that are BEGIN and END indexed. bobb >>> Brent Fraser wrote: Bob, What kinds of things are you trying to do with layers? Are the layers vectors? Maybe there's a different way... I'm in the midst of an implementation where the vectors are held in PostGIS in three tables (point, line and polygon) and joined to a "feature definition" table (to supply rendering values). I use one map file with three layers (point, line, polygon) and pass a FILTER variable to get my different layers which are then rendered. Here's a snippet from the polygon layer: CLASS STYLE # Polygon Fill SYMBOL [polyfill_symbol] COLOR [polyfill_fillcolor] ANGLE [polyfill_angle] SIZE [polyfill_hatchgap] # e.g Hatching gap WIDTH 1 # [polyfill_hatchthick] # Hatching line thickness (column binding doesn't seem to work) # OPACITY 50 # [attribute] # warning: there is no OPACITY for LABEL so don't bother. END STYLE # Polygon Outline SYMBOL [geom_symbol] OUTLINECOLOR [geom_outcolor] SIZE [geom_width] # for "simple" (?) symbols WIDTH [geom_width] # for complex symbols END # Style TEXT ([gid]) LABEL TYPE TRUETYPE FONT [label_font] ANTIALIAS TRUE COLOR [label_fillcolor] OUTLINECOLOR [label_outcolor] BUFFER 1 POSITION cc # [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] PARTIALS TRUE SIZE [label_height] END # LABEL END # class While this method is suitable for rendering, it will be a problem if you want store variables for use in an identify operation (or maybe not; I wonder if a template name can be bound to a database column...) Best Regards, Brent Fraser On 4/16/2012 10:22 AM, Bob Basques wrote: All, Did anything ever develop from this idea? I need to generate a variable length list of layers pro grammatically. I'm not finding anything from a quick search of things related to passing a MAPFILE via the CGI call. I want to be able to generate a MAPFILE, or chunks of it, on the fly. A possible solution (maybe scary security wise) would be to use a param like "INCLUDE_=", to pass in MAP fragments to an existing MAPFILE. I need to essentially add layers. Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be to have MapServer build it's own MAPFILE as a TEMPLATE output, but I'm not coming up with a way immediately of passing the resulting MAPFILE to Mapserver in the end. bobb _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Mon Apr 16 12:33:52 2012 From: bfraser at geoanalytic.com (Brent Fraser) Date: Mon, 16 Apr 2012 13:33:52 -0600 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C2790020000A80003541D@heckle> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> <4F8C2790020000A80003541D@heckle> Message-ID: <4F8C7420.30705@geoanalytic.com> Well, in this application I don't care about a feature's real-world attributes (only the geometry and their feature "class"), so I'm able to pack all polygons into one table. I then join the polygon table to the feature class table to get the color, etc. Are you representing each GPS trail as a separate layer? So the user can turn individual trail on/off in a layer control? Best Regards, Brent Fraser On 4/16/2012 1:07 PM, Bob Basques wrote: > > Hmm, interesting apporach, reminds me of my ealier days with Oracle > (before Oracle Spatial, where each feature type needed it's own table > structure . . . Have to do some more thinking on this one. > > > I'm trying to render a predefined list of layers (from the user) of a > set of GPS trails that are BEGIN and END indexed. > > > bobb > > > > > >>> Brent Fraser wrote: > > Bob, > > What kinds of things are you trying to do with layers? Are the > layers vectors? Maybe there's a different way... > > I'm in the midst of an implementation where the vectors are held in > PostGIS in three tables (point, line and polygon) and joined to a > "feature definition" table (to supply rendering values). I use one > map file with three layers (point, line, polygon) and pass a FILTER > variable to get my different layers which are then rendered. > > Here's a snippet from the polygon layer: > > CLASS > STYLE # Polygon Fill > SYMBOL [polyfill_symbol] > COLOR [polyfill_fillcolor] > ANGLE [polyfill_angle] > SIZE [polyfill_hatchgap] # e.g Hatching gap > WIDTH 1 # [polyfill_hatchthick] # Hatching > line thickness (column binding doesn't seem to work) > # OPACITY 50 # [attribute] # warning: there is no > OPACITY for LABEL so don't bother. > END > STYLE # Polygon Outline > SYMBOL [geom_symbol] > OUTLINECOLOR [geom_outcolor] > SIZE [geom_width] # for "simple" (?) symbols > WIDTH [geom_width] # for complex symbols > END # Style > TEXT ([gid]) > LABEL > TYPE TRUETYPE > FONT [label_font] > ANTIALIAS TRUE > COLOR [label_fillcolor] > OUTLINECOLOR [label_outcolor] > BUFFER 1 > POSITION cc # [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] > PARTIALS TRUE > SIZE [label_height] > END # LABEL > > END # class > > While this method is suitable for rendering, it will be a problem if > you want store variables for use in an identify operation (or maybe > not; I wonder if a template name can be bound to a database column...) > > Best Regards, > > > > > Brent Fraser > > > > On 4/16/2012 10:22 AM, Bob Basques wrote: > >> All, >> >> >> Did anything ever develop from this idea? I need to generate a >> variable length list of layers pro grammatically. >> >> >> I'm not finding anything from a quick search of things related to >> passing a MAPFILE via the CGI call. I want to be able to generate a >> MAPFILE, or chunks of it, on the fly. A possible solution (maybe >> scary security wise) would be to use a param like >> "INCLUDE_=", to pass in MAP fragments to an existing MAPFILE. >> I need to essentially add layers. >> >> >> Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be >> to have MapServer build it's own MAPFILE as a TEMPLATE output, but >> I'm not coming up with a way immediately of passing the resulting >> MAPFILE to Mapserver in the end. >> >> >> bobb >> >> >> >> >> _______________________________________________ >> >> >> >> >> mapserver-users mailing list >> >> >> >> >> mapserver-users at lists.osgeo.org >> >> >> >> >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Mon Apr 16 12:41:43 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Mon, 16 Apr 2012 14:41:43 -0500 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C7420.30705@geoanalytic.com> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> <4F8C2790020000A80003541D@heckle> <4F8C7420.30705@geoanalytic.com> Message-ID: <4F8C2FA7020000A800035435@heckle> Individual trails, one layer per GPS to allow user control of visibility. bobb >>> Brent Fraser wrote: Well, in this application I don't care about a feature's real-world attributes (only the geometry and their feature "class"), so I'm able to pack all polygons into one table. I then join the polygon table to the feature class table to get the color, etc. Are you representing each GPS trail as a separate layer? So the user can turn individual trail on/off in a layer control? Best Regards, Brent Fraser On 4/16/2012 1:07 PM, Bob Basques wrote: Hmm, interesting apporach, reminds me of my ealier days with Oracle (before Oracle Spatial, where each feature type needed it's own table structure . . . Have to do some more thinking on this one. I'm trying to render a predefined list of layers (from the user) of a set of GPS trails that are BEGIN and END indexed. bobb >>> Brent Fraser ( mailto:bfraser at geoanalytic.com ) wrote: Bob, What kinds of things are you trying to do with layers? Are the layers vectors? Maybe there's a different way... I'm in the midst of an implementation where the vectors are held in PostGIS in three tables (point, line and polygon) and joined to a "feature definition" table (to supply rendering values). I use one map file with three layers (point, line, polygon) and pass a FILTER variable to get my different layers which are then rendered. Here's a snippet from the polygon layer: CLASS STYLE # Polygon Fill SYMBOL [polyfill_symbol] COLOR [polyfill_fillcolor] ANGLE [polyfill_angle] SIZE [polyfill_hatchgap] # e.g Hatching gap WIDTH 1 # [polyfill_hatchthick] # Hatching line thickness (column binding doesn't seem to work) # OPACITY 50 # [attribute] # warning: there is no OPACITY for LABEL so don't bother. END STYLE # Polygon Outline SYMBOL [geom_symbol] OUTLINECOLOR [geom_outcolor] SIZE [geom_width] # for "simple" (?) symbols WIDTH [geom_width] # for complex symbols END # Style TEXT ([gid]) LABEL TYPE TRUETYPE FONT [label_font] ANTIALIAS TRUE COLOR [label_fillcolor] OUTLINECOLOR [label_outcolor] BUFFER 1 POSITION cc # [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] PARTIALS TRUE SIZE [label_height] END # LABEL END # class While this method is suitable for rendering, it will be a problem if you want store variables for use in an identify operation (or maybe not; I wonder if a template name can be bound to a database column...) Best Regards, Brent Fraser On 4/16/2012 10:22 AM, Bob Basques wrote: All, Did anything ever develop from this idea? I need to generate a variable length list of layers pro grammatically. I'm not finding anything from a quick search of things related to passing a MAPFILE via the CGI call. I want to be able to generate a MAPFILE, or chunks of it, on the fly. A possible solution (maybe scary security wise) would be to use a param like "INCLUDE_=", to pass in MAP fragments to an existing MAPFILE. I need to essentially add layers. Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be to have MapServer build it's own MAPFILE as a TEMPLATE output, but I'm not coming up with a way immediately of passing the resulting MAPFILE to Mapserver in the end. bobb _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Mon Apr 16 12:54:52 2012 From: bfraser at geoanalytic.com (Brent Fraser) Date: Mon, 16 Apr 2012 13:54:52 -0600 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C2FA7020000A800035435@heckle> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> <4F8C2790020000A80003541D@heckle> <4F8C7420.30705@geoanalytic.com> <4F8C2FA7020000A800035435@heckle> Message-ID: <4F8C790C.1060202@geoanalytic.com> I guess my solution would be to put the trails in a PostGIS table: Trails: id name geometry 1 trail A 234523452345 2 trail B 5879567876454 Use one map file with a FILTER "name='%trail_name%'". Now use http://.../mapserv?trail_name="trail A" to have mapserver do the variable substitution in the mapfile. The bigger problem is generating the GUI layer list with the pointers to the mapserver URLs. A script/database generated mapbook in GeoMoose, or JavaScript list for use with OpenLayers, etc... Best Regards, Brent Fraser On 4/16/2012 1:41 PM, Bob Basques wrote: > > Individual trails, one layer per GPS to allow user control of visibility. > > > bobb > > > > > >>> Brent Fraser wrote: > > Well, in this application I don't care about a feature's real-world > attributes (only the geometry and their feature "class"), so I'm able > to pack all polygons into one table. I then join the polygon table to > the feature class table to get the color, etc. > > Are you representing each GPS trail as a separate layer? So the user > can turn individual trail on/off in a layer control? > > Best Regards, > > > > > Brent Fraser > > > > On 4/16/2012 1:07 PM, Bob Basques wrote: > >> Hmm, interesting apporach, reminds me of my ealier days with Oracle >> (before Oracle Spatial, where each feature type needed it's own table >> structure . . . Have to do some more thinking on this one. >> >> >> I'm trying to render a predefined list of layers (from the user) of a >> set of GPS trails that are BEGIN and END indexed. >> >> >> bobb >> >> >> >> >> >>> Brent Fraser wrote: >> >> Bob, >> >> What kinds of things are you trying to do with layers? Are the >> layers vectors? Maybe there's a different way... >> >> I'm in the midst of an implementation where the vectors are held in >> PostGIS in three tables (point, line and polygon) and joined to a >> "feature definition" table (to supply rendering values). I use one >> map file with three layers (point, line, polygon) and pass a FILTER >> variable to get my different layers which are then rendered. >> >> Here's a snippet from the polygon layer: >> >> CLASS >> STYLE # Polygon Fill >> SYMBOL [polyfill_symbol] >> COLOR [polyfill_fillcolor] >> ANGLE [polyfill_angle] >> SIZE [polyfill_hatchgap] # e.g Hatching gap >> WIDTH 1 # [polyfill_hatchthick] # Hatching >> line thickness (column binding doesn't seem to work) >> # OPACITY 50 # [attribute] # warning: there is >> no OPACITY for LABEL so don't bother. >> END >> STYLE # Polygon Outline >> SYMBOL [geom_symbol] >> OUTLINECOLOR [geom_outcolor] >> SIZE [geom_width] # for "simple" (?) symbols >> WIDTH [geom_width] # for complex symbols >> END # Style >> TEXT ([gid]) >> LABEL >> TYPE TRUETYPE >> FONT [label_font] >> ANTIALIAS TRUE >> COLOR [label_fillcolor] >> OUTLINECOLOR [label_outcolor] >> BUFFER 1 >> POSITION cc # >> [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] >> PARTIALS TRUE >> SIZE [label_height] >> END # LABEL >> >> END # class >> >> While this method is suitable for rendering, it will be a problem if >> you want store variables for use in an identify operation (or maybe >> not; I wonder if a template name can be bound to a database column...) >> >> Best Regards, >> >> >> >> >> >> Brent Fraser >> >> >> >> >> >> On 4/16/2012 10:22 AM, Bob Basques wrote: >> >>> All, >>> >>> >>> Did anything ever develop from this idea? I need to generate a >>> variable length list of layers pro grammatically. >>> >>> >>> I'm not finding anything from a quick search of things related to >>> passing a MAPFILE via the CGI call. I want to be able to generate a >>> MAPFILE, or chunks of it, on the fly. A possible solution (maybe >>> scary security wise) would be to use a param like >>> "INCLUDE_=", to pass in MAP fragments to an existing >>> MAPFILE. I need to essentially add layers. >>> >>> >>> Another thought I had (Ok, it's a bit odd, I'll admit . . .) would >>> be to have MapServer build it's own MAPFILE as a TEMPLATE output, >>> but I'm not coming up with a way immediately of passing the >>> resulting MAPFILE to Mapserver in the end. >>> >>> >>> bobb >>> >>> >>> >>> >>> _______________________________________________ >>> >>> >>> >>> >>> >>> mapserver-users mailing list >>> >>> >>> >>> >>> >>> mapserver-users at lists.osgeo.org >>> >>> >>> >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> >>> >>> -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Mon Apr 16 13:07:49 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Mon, 16 Apr 2012 15:07:49 -0500 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C790C.1060202@geoanalytic.com> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> <4F8C2790020000A80003541D@heckle> <4F8C7420.30705@geoanalytic.com> <4F8C2FA7020000A800035435@heckle> <4F8C790C.1060202@geoanalytic.com> Message-ID: <4F8C35C5020000A800035450@heckle> Yeah, the problem is, the list of GPSs is variable. It's all in POSTGIS now, and by GPS name. bobb >>> Brent Fraser wrote: I guess my solution would be to put the trails in a PostGIS table: Trails: id name geometry 1 trail A 234523452345 2 trail B 5879567876454 Use one map file with a FILTER "name='%trail_name%'". Now use http://.../mapserv?trail_name="trail A" to have mapserver do the variable substitution in the mapfile. The bigger problem is generating the GUI layer list with the pointers to the mapserver URLs. A script/database generated mapbook in GeoMoose, or JavaScript list for use with OpenLayers, etc... Best Regards, Brent Fraser On 4/16/2012 1:41 PM, Bob Basques wrote: Individual trails, one layer per GPS to allow user control of visibility. bobb >>> Brent Fraser ( mailto:bfraser at geoanalytic.com ) wrote: Well, in this application I don't care about a feature's real-world attributes (only the geometry and their feature "class"), so I'm able to pack all polygons into one table. I then join the polygon table to the feature class table to get the color, etc. Are you representing each GPS trail as a separate layer? So the user can turn individual trail on/off in a layer control? Best Regards, Brent Fraser On 4/16/2012 1:07 PM, Bob Basques wrote: Hmm, interesting apporach, reminds me of my ealier days with Oracle (before Oracle Spatial, where each feature type needed it's own table structure . . . Have to do some more thinking on this one. I'm trying to render a predefined list of layers (from the user) of a set of GPS trails that are BEGIN and END indexed. bobb >>> Brent Fraser ( mailto:bfraser at geoanalytic.com ) wrote: Bob, What kinds of things are you trying to do with layers? Are the layers vectors? Maybe there's a different way... I'm in the midst of an implementation where the vectors are held in PostGIS in three tables (point, line and polygon) and joined to a "feature definition" table (to supply rendering values). I use one map file with three layers (point, line, polygon) and pass a FILTER variable to get my different layers which are then rendered. Here's a snippet from the polygon layer: CLASS STYLE # Polygon Fill SYMBOL [polyfill_symbol] COLOR [polyfill_fillcolor] ANGLE [polyfill_angle] SIZE [polyfill_hatchgap] # e.g Hatching gap WIDTH 1 # [polyfill_hatchthick] # Hatching line thickness (column binding doesn't seem to work) # OPACITY 50 # [attribute] # warning: there is no OPACITY for LABEL so don't bother. END STYLE # Polygon Outline SYMBOL [geom_symbol] OUTLINECOLOR [geom_outcolor] SIZE [geom_width] # for "simple" (?) symbols WIDTH [geom_width] # for complex symbols END # Style TEXT ([gid]) LABEL TYPE TRUETYPE FONT [label_font] ANTIALIAS TRUE COLOR [label_fillcolor] OUTLINECOLOR [label_outcolor] BUFFER 1 POSITION cc # [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] PARTIALS TRUE SIZE [label_height] END # LABEL END # class While this method is suitable for rendering, it will be a problem if you want store variables for use in an identify operation (or maybe not; I wonder if a template name can be bound to a database column...) Best Regards, Brent Fraser On 4/16/2012 10:22 AM, Bob Basques wrote: All, Did anything ever develop from this idea? I need to generate a variable length list of layers pro grammatically. I'm not finding anything from a quick search of things related to passing a MAPFILE via the CGI call. I want to be able to generate a MAPFILE, or chunks of it, on the fly. A possible solution (maybe scary security wise) would be to use a param like "INCLUDE_=", to pass in MAP fragments to an existing MAPFILE. I need to essentially add layers. Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be to have MapServer build it's own MAPFILE as a TEMPLATE output, but I'm not coming up with a way immediately of passing the resulting MAPFILE to Mapserver in the end. bobb _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Mon Apr 16 13:49:46 2012 From: bfraser at geoanalytic.com (Brent Fraser) Date: Mon, 16 Apr 2012 14:49:46 -0600 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C35C5020000A800035450@heckle> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> <4F8C2790020000A80003541D@heckle> <4F8C7420.30705@geoanalytic.com> <4F8C2FA7020000A800035435@heckle> <4F8C790C.1060202@geoanalytic.com> <4F8C35C5020000A800035450@heckle> Message-ID: <4F8C85EA.1010606@geoanalytic.com> It would make an interesting user extension in GeoMoose: - Based on some GUI trigger (a button?), request a list of layers from a URL (hey, a "getCapabilites" style service!), and populate/replace the layer list in the catalog. That would be cool... Best Regards, Brent Fraser On 4/16/2012 2:07 PM, Bob Basques wrote: > > Yeah, the problem is, the list of GPSs is variable. > > > It's all in POSTGIS now, and by GPS name. > > > bobb > > > > > >>> Brent Fraser wrote: > > I guess my solution would be to put the trails in a PostGIS table: > > Trails: > id name geometry > 1 trail A 234523452345 > 2 trail B 5879567876454 > > Use one map file with a FILTER "name='%trail_name%'". Now use > http://.../mapserv?trail_name="trail A" to have mapserver do the > variable substitution in the mapfile. > > The bigger problem is generating the GUI layer list with the pointers > to the mapserver URLs. A script/database generated mapbook in > GeoMoose, or JavaScript list for use with OpenLayers, etc... > > Best Regards, > > > > > Brent Fraser > > > > On 4/16/2012 1:41 PM, Bob Basques wrote: > >> Individual trails, one layer per GPS to allow user control of >> visibility. >> >> >> bobb >> >> >> >> >> >>> Brent Fraser wrote: >> >> Well, in this application I don't care about a feature's real-world >> attributes (only the geometry and their feature "class"), so I'm >> able to pack all polygons into one table. I then join the polygon >> table to the feature class table to get the color, etc. >> >> Are you representing each GPS trail as a separate layer? So the user >> can turn individual trail on/off in a layer control? >> >> Best Regards, >> >> >> >> >> >> Brent Fraser >> >> >> >> >> >> On 4/16/2012 1:07 PM, Bob Basques wrote: >> >>> Hmm, interesting apporach, reminds me of my ealier days with Oracle >>> (before Oracle Spatial, where each feature type needed it's own >>> table structure . . . Have to do some more thinking on this one. >>> >>> >>> I'm trying to render a predefined list of layers (from the user) of >>> a set of GPS trails that are BEGIN and END indexed. >>> >>> >>> bobb >>> >>> >>> >>> >>> >>> Brent Fraser wrote: >>> >>> Bob, >>> >>> What kinds of things are you trying to do with layers? Are the >>> layers vectors? Maybe there's a different way... >>> >>> I'm in the midst of an implementation where the vectors are held in >>> PostGIS in three tables (point, line and polygon) and joined to a >>> "feature definition" table (to supply rendering values). I use one >>> map file with three layers (point, line, polygon) and pass a FILTER >>> variable to get my different layers which are then rendered. >>> >>> Here's a snippet from the polygon layer: >>> >>> CLASS >>> STYLE # Polygon Fill >>> SYMBOL [polyfill_symbol] >>> COLOR [polyfill_fillcolor] >>> ANGLE [polyfill_angle] >>> SIZE [polyfill_hatchgap] # e.g Hatching gap >>> WIDTH 1 # [polyfill_hatchthick] # Hatching >>> line thickness (column binding doesn't seem to work) >>> # OPACITY 50 # [attribute] # warning: there is >>> no OPACITY for LABEL so don't bother. >>> END >>> STYLE # Polygon Outline >>> SYMBOL [geom_symbol] >>> OUTLINECOLOR [geom_outcolor] >>> SIZE [geom_width] # for "simple" (?) symbols >>> WIDTH [geom_width] # for complex symbols >>> END # Style >>> TEXT ([gid]) >>> LABEL >>> TYPE TRUETYPE >>> FONT [label_font] >>> ANTIALIAS TRUE >>> COLOR [label_fillcolor] >>> OUTLINECOLOR [label_outcolor] >>> BUFFER 1 >>> POSITION cc # >>> [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] >>> PARTIALS TRUE >>> SIZE [label_height] >>> END # LABEL >>> >>> END # class >>> >>> While this method is suitable for rendering, it will be a problem if >>> you want store variables for use in an identify operation (or maybe >>> not; I wonder if a template name can be bound to a database column...) >>> >>> >>> >>> >>> Best Regards, >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> Brent Fraser >>> >>> >>> >>> >>> >>> >>> >>> On 4/16/2012 10:22 AM, Bob Basques wrote: >>> >>>> All, >>>> >>>> >>>> Did anything ever develop from this idea? I need to generate a >>>> variable length list of layers pro grammatically. >>>> >>>> >>>> I'm not finding anything from a quick search of things related to >>>> passing a MAPFILE via the CGI call. I want to be able to generate >>>> a MAPFILE, or chunks of it, on the fly. A possible solution (maybe >>>> scary security wise) would be to use a param like >>>> "INCLUDE_=", to pass in MAP fragments to an existing >>>> MAPFILE. I need to essentially add layers. >>>> >>>> >>>> Another thought I had (Ok, it's a bit odd, I'll admit . . .) would >>>> be to have MapServer build it's own MAPFILE as a TEMPLATE output, >>>> but I'm not coming up with a way immediately of passing the >>>> resulting MAPFILE to Mapserver in the end. >>>> >>>> >>>> bobb >>>> >>>> >>>> >>>> >>>> >>>> >>>> _______________________________________________ >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> mapserver-users mailing list >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> mapserver-users at lists.osgeo.org >>>> >>>> >>>> >>>> >>>> >>>> >>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>>> >>>> >>>> >>>> -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Mon Apr 16 13:56:13 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Mon, 16 Apr 2012 15:56:13 -0500 Subject: [mapserver-users] Passing a mapfile via CGI In-Reply-To: <4F8C85EA.1010606@geoanalytic.com> References: <4F8C0113020000A8000353FC@heckle> <4F8C4BB1.5000108@geoanalytic.com> <4F8C2790020000A80003541D@heckle> <4F8C7420.30705@geoanalytic.com> <4F8C2FA7020000A800035435@heckle> <4F8C790C.1060202@geoanalytic.com> <4F8C35C5020000A800035450@heckle> <4F8C85EA.1010606@geoanalytic.com> Message-ID: <4F8C411D020000A800035469@heckle> Actually, I'm working on that very capability in another project right now. A bit more comprehensive in the details. Exact functionality you just described though. bobb >>> Brent Fraser wrote: It would make an interesting user extension in GeoMoose: - Based on some GUI trigger (a button?), request a list of layers from a URL (hey, a "getCapabilites" style service!), and populate/replace the layer list in the catalog. That would be cool... Best Regards, Brent Fraser On 4/16/2012 2:07 PM, Bob Basques wrote: Yeah, the problem is, the list of GPSs is variable. It's all in POSTGIS now, and by GPS name. bobb >>> Brent Fraser ( mailto:bfraser at geoanalytic.com ) wrote: I guess my solution would be to put the trails in a PostGIS table: Trails: id name geometry 1 trail A 234523452345 2 trail B 5879567876454 Use one map file with a FILTER "name='%trail_name%'". Now use http://.../mapserv?trail_name="trail A" to have mapserver do the variable substitution in the mapfile. The bigger problem is generating the GUI layer list with the pointers to the mapserver URLs. A script/database generated mapbook in GeoMoose, or JavaScript list for use with OpenLayers, etc... Best Regards, Brent Fraser On 4/16/2012 1:41 PM, Bob Basques wrote: Individual trails, one layer per GPS to allow user control of visibility. bobb >>> Brent Fraser ( mailto:bfraser at geoanalytic.com ) wrote: Well, in this application I don't care about a feature's real-world attributes (only the geometry and their feature "class"), so I'm able to pack all polygons into one table. I then join the polygon table to the feature class table to get the color, etc. Are you representing each GPS trail as a separate layer? So the user can turn individual trail on/off in a layer control? Best Regards, Brent Fraser On 4/16/2012 1:07 PM, Bob Basques wrote: Hmm, interesting apporach, reminds me of my ealier days with Oracle (before Oracle Spatial, where each feature type needed it's own table structure . . . Have to do some more thinking on this one. I'm trying to render a predefined list of layers (from the user) of a set of GPS trails that are BEGIN and END indexed. bobb >>> Brent Fraser ( mailto:bfraser at geoanalytic.com ) wrote: Bob, What kinds of things are you trying to do with layers? Are the layers vectors? Maybe there's a different way... I'm in the midst of an implementation where the vectors are held in PostGIS in three tables (point, line and polygon) and joined to a "feature definition" table (to supply rendering values). I use one map file with three layers (point, line, polygon) and pass a FILTER variable to get my different layers which are then rendered. Here's a snippet from the polygon layer: CLASS STYLE # Polygon Fill SYMBOL [polyfill_symbol] COLOR [polyfill_fillcolor] ANGLE [polyfill_angle] SIZE [polyfill_hatchgap] # e.g Hatching gap WIDTH 1 # [polyfill_hatchthick] # Hatching line thickness (column binding doesn't seem to work) # OPACITY 50 # [attribute] # warning: there is no OPACITY for LABEL so don't bother. END STYLE # Polygon Outline SYMBOL [geom_symbol] OUTLINECOLOR [geom_outcolor] SIZE [geom_width] # for "simple" (?) symbols WIDTH [geom_width] # for complex symbols END # Style TEXT ([gid]) LABEL TYPE TRUETYPE FONT [label_font] ANTIALIAS TRUE COLOR [label_fillcolor] OUTLINECOLOR [label_outcolor] BUFFER 1 POSITION cc # [ul|uc|ur|cl|cc|cr|ll|lc|lr|auto] PARTIALS TRUE SIZE [label_height] END # LABEL END # class While this method is suitable for rendering, it will be a problem if you want store variables for use in an identify operation (or maybe not; I wonder if a template name can be bound to a database column...) Best Regards, Brent Fraser On 4/16/2012 10:22 AM, Bob Basques wrote: All, Did anything ever develop from this idea? I need to generate a variable length list of layers pro grammatically. I'm not finding anything from a quick search of things related to passing a MAPFILE via the CGI call. I want to be able to generate a MAPFILE, or chunks of it, on the fly. A possible solution (maybe scary security wise) would be to use a param like "INCLUDE_=", to pass in MAP fragments to an existing MAPFILE. I need to essentially add layers. Another thought I had (Ok, it's a bit odd, I'll admit . . .) would be to have MapServer build it's own MAPFILE as a TEMPLATE output, but I'm not coming up with a way immediately of passing the resulting MAPFILE to Mapserver in the end. bobb _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From quansheng.cs at gmail.com Tue Apr 17 09:17:49 2012 From: quansheng.cs at gmail.com (Li Quansheng) Date: Wed, 18 Apr 2012 00:17:49 +0800 Subject: [mapserver-users] mapserver 5.6 CGI output GeoJSON format Message-ID: hi guys, I installed FGS 5.6.3 on my VM to do some studying, these days I want to add WFS layer to my applyaction via openlayers, and I want to do some WFS query to output GeoJSON, I do my best, now,there is one problem I can't ?figure out. my mapfile: (mapserver 5.6) .... ?OUTPUTFORMAT ? ?NAME "geojson" ? ?DRIVER "TEMPLATE" ? ?MIMETYPE "application/json; subtype=geojson" ? ?FORMATOPTION "FILE=xj1JSON.tmpl" ?END ... ? ?METADATA ? ? ?'ows_title' ? ? ? ? ? 'XJ-MAP' ? #OWS (OGC Web Services) ? ? ?'ows_onlineresource' 'http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map' ? ? ?'ows_srs' ? ? ? ? ? ? 'EPSG:4326' ? ? ?'wms_tile' ? ? ? ? ? ?'xjmap' ?'wms_onlineresource' 'http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map' ?'wms_srs' ? ?'EPSG:4326 EPSG:900913' ?"wfs_title" ? ? ? ? ?"xjmap" ? ? ?"wfs_onlineresource" "http://192.168.207.100/cgin-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&" ? ? ?"wfs_srs" ? ? ? ? ? ?"EPSG:4326 EPSG:900913" ## Recommended ? ? ?"wfs_abstract" ? ? ? "xjmap WFS service." ## Recommended ? ? ?"wfs_enable_request" "*" ?# necessary,?*? enables all requests ?"wfs_encoding" ? "UTF-8" ? ?END .... ?LAYER ? ?NAME 'tielu' ? ?TYPE LINE ? ?DUMP true ? ?TEMPLATE fooOnlyForWMSGetFeatureInfo ?EXTENT 70.409351 33.963843 99.420299 49.549665 CONNECTIONTYPE postgis ? ? ? ?CONNECTION "host=localhost dbname=xj1 user=xxx password=xxx" PROCESSING "CLOSE_CONNECTION=DEFER" DATA "the_geom from tielu" ? ?METADATA ? ? ?'ows_title' 'tielu' ?"wfs_title" ? ? ? ? "tielu" ##REQUIRED ? ? ?"wfs_srs" ? ? ? ? ? "EPSG:4326" ## REQUIRED ?"wfs_featureid" ? ? "gid" ?#"wfs_getfeature_formatlist" "geojson" # mapserver 6.0 support ? ? ?"gml_include_items" "all" ## Optional (serves all attributes for layer) ? ? ?"gml_featureid" ? ? "gid" ## REQUIRED ? ? ?"wfs_enable_request" "*" ? ?END ? ?STATUS OFF ? ?TRANSPARENCY 100 ? ?PROJECTION ? ?'proj=longlat' ? ?'datum=WGS84' ? ?'no_defs' ? ?END ? ?CLASS ? ? ? NAME 'tielu' ? ? ? STYLE ? ? ? ? WIDTH 0.91 ? ? ? ? COLOR 164 229 51 ? ? ? END ? ?END ?END .... the GeoJson outputformat ?template file xj1JSON.tmpl // mapserver template [resultset layer=tielu] { ?"type": "FeatureCollection", ?"features": [ ? ?[feature limit=-1 feature trimlast=","] ? ?{ ? ? ?"type": "Feature", ? ? ?"id": "[gid]", ? ? ?"geometry": { ? ? ? ?"type": "MultiLineString", ? ? ? ?"coordinates": [ "coordinates": [[[shpxy]]] ? ? ? ?] ? ? ?}, ? ? ?"properties": { ? ? ? ?"gid": "[gid]", ? ? ? ?"type": "[type]", ? ? ? ?"name": "[name]" ? ? ?} ? ?}, ? ?[/feature] ?] } [/resultset] I want to output the "tielu" multiline layer , I can success execute the http request, http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qformat=geojson , It seemed that all the GeoJSON output is perfect except ?the output coordinates of the colum the_geom. the output is as flowings: { "type": "FeatureCollection", "features": [ { "type": "Feature", "id": "1", "geometry": { "type": "MultiLineString", "coordinates": [ "coordinates": [[84,42 84,42 84,42 84,42 83,42 83,42 83,42 83,42 83,42 83,42]] //there is sth wrong here! ] }, "properties": { "gid": "1", "type": "70", "name": "name111" } }, .... ] } I think sth wrong in my template file about "coordinates": [[[shpxy]]], I do many google searching,try my best to correct the file,I try "coordinates": [[LONG], [LAT]] etc, , but I failed, Could anyone give me some advice, thank you very much! From Steve.Lime at state.mn.us Tue Apr 17 11:58:25 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Tue, 17 Apr 2012 18:58:25 +0000 Subject: [mapserver-users] mapserver 5.6 CGI output GeoJSON format In-Reply-To: References: Message-ID: So the problem with the coordinates is they are truncated or ??? Not having the spec handy what would the correct output be? There are several arguments to the shpxy tag that will probably be of help. For example you might add: [shpxy precision="6"] Steve -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Li Quansheng Sent: Tuesday, April 17, 2012 11:18 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] mapserver 5.6 CGI output GeoJSON format hi guys, I installed FGS 5.6.3 on my VM to do some studying, these days I want to add WFS layer to my applyaction via openlayers, and I want to do some WFS query to output GeoJSON, I do my best, now,there is one problem I can't ?figure out. my mapfile: (mapserver 5.6) .... ?OUTPUTFORMAT ? ?NAME "geojson" ? ?DRIVER "TEMPLATE" ? ?MIMETYPE "application/json; subtype=geojson" ? ?FORMATOPTION "FILE=xj1JSON.tmpl" ?END ... ? ?METADATA ? ? ?'ows_title' ? ? ? ? ? 'XJ-MAP' ? #OWS (OGC Web Services) ? ? ?'ows_onlineresource' 'http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map' ? ? ?'ows_srs' ? ? ? ? ? ? 'EPSG:4326' ? ? ?'wms_tile' ? ? ? ? ? ?'xjmap' ?'wms_onlineresource' 'http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map' ?'wms_srs' ? ?'EPSG:4326 EPSG:900913' ?"wfs_title" ? ? ? ? ?"xjmap" ? ? ?"wfs_onlineresource" "http://192.168.207.100/cgin-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&" ? ? ?"wfs_srs" ? ? ? ? ? ?"EPSG:4326 EPSG:900913" ## Recommended ? ? ?"wfs_abstract" ? ? ? "xjmap WFS service." ## Recommended ? ? ?"wfs_enable_request" "*" ?# necessary,"*" enables all requests ?"wfs_encoding" ? "UTF-8" ? ?END .... ?LAYER ? ?NAME 'tielu' ? ?TYPE LINE ? ?DUMP true ? ?TEMPLATE fooOnlyForWMSGetFeatureInfo ?EXTENT 70.409351 33.963843 99.420299 49.549665 CONNECTIONTYPE postgis ? ? ? ?CONNECTION "host=localhost dbname=xj1 user=xxx password=xxx" PROCESSING "CLOSE_CONNECTION=DEFER" DATA "the_geom from tielu" ? ?METADATA ? ? ?'ows_title' 'tielu' ?"wfs_title" ? ? ? ? "tielu" ##REQUIRED ? ? ?"wfs_srs" ? ? ? ? ? "EPSG:4326" ## REQUIRED ?"wfs_featureid" ? ? "gid" ?#"wfs_getfeature_formatlist" "geojson" # mapserver 6.0 support ? ? ?"gml_include_items" "all" ## Optional (serves all attributes for layer) ? ? ?"gml_featureid" ? ? "gid" ## REQUIRED ? ? ?"wfs_enable_request" "*" ? ?END ? ?STATUS OFF ? ?TRANSPARENCY 100 ? ?PROJECTION ? ?'proj=longlat' ? ?'datum=WGS84' ? ?'no_defs' ? ?END ? ?CLASS ? ? ? NAME 'tielu' ? ? ? STYLE ? ? ? ? WIDTH 0.91 ? ? ? ? COLOR 164 229 51 ? ? ? END ? ?END ?END .... the GeoJson outputformat ?template file xj1JSON.tmpl // mapserver template [resultset layer=tielu] { ?"type": "FeatureCollection", ?"features": [ ? ?[feature limit=-1 feature trimlast=","] ? ?{ ? ? ?"type": "Feature", ? ? ?"id": "[gid]", ? ? ?"geometry": { ? ? ? ?"type": "MultiLineString", ? ? ? ?"coordinates": [ "coordinates": [[[shpxy]]] ? ? ? ?] ? ? ?}, ? ? ?"properties": { ? ? ? ?"gid": "[gid]", ? ? ? ?"type": "[type]", ? ? ? ?"name": "[name]" ? ? ?} ? ?}, ? ?[/feature] ?] } [/resultset] I want to output the "tielu" multiline layer , I can success execute the http request, http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qformat=geojson , It seemed that all the GeoJSON output is perfect except ?the output coordinates of the colum the_geom. the output is as flowings: { "type": "FeatureCollection", "features": [ { "type": "Feature", "id": "1", "geometry": { "type": "MultiLineString", "coordinates": [ "coordinates": [[84,42 84,42 84,42 84,42 83,42 83,42 83,42 83,42 83,42 83,42]] //there is sth wrong here! ] }, "properties": { "gid": "1", "type": "70", "name": "name111" } }, .... ] } I think sth wrong in my template file about "coordinates": [[[shpxy]]], I do many google searching,try my best to correct the file,I try "coordinates": [[LONG], [LAT]] etc, , but I failed, Could anyone give me some advice, thank you very much! _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From quansheng.cs at gmail.com Wed Apr 18 01:31:04 2012 From: quansheng.cs at gmail.com (Li Quansheng) Date: Wed, 18 Apr 2012 16:31:04 +0800 Subject: [mapserver-users] mapserver CGI GeoJSON output Message-ID: hi Steve,guys I really don't know where the coordinates are truncated or not. In facct, I couldn't find the reason cause the output problem. the output is as flowings: { "type": "FeatureCollection", "features": [ { "type": "Feature", "id": "1", "geometry": { "type": "MultiLineString", "coordinates": [ "coordinates": [[84,42 84,42 84,42 84,42 83,42 83,42 83,42 83,42 83,42 83,42]] ] }, "properties": { "gid": "1", "type": "70", "name": "name111" } }, ... { "type": "Feature", "id": "3", "geometry": { "type": "MultiLineString", "coordinates": [ "coordinates": [[83,42 83,42 83,42 83,42 83,42]] ] }, "properties": { "gid": "3", "type": "70", "name": "name333" } }, .... ........ ] } But I exectue the SQL from pgAdmin III,select gid,type,ST_AsGeoJSON(the_geom) from tielu IN pgAdmin I output the SQL so you can see the output exactely, {"type":"MultiLineString","coordinates":[[[83.981538,41.839139000000003],[83.945753999999994,41.838410000000003],[83.916893000000002,41.834904999999999],[83.687324000000004,41.810006000000001],[83.232517999999999,41.753878999999998],[83.223220999999995,41.752234000000001],[83.221637999999999,41.750559000000003],[83.216065999999998,41.741002999999999],[83.144756999999998,41.724834000000001],[83.030783,41.697861000000003]]]} {"type":"MultiLineString","coordinates":[[[83.022717,41.695501999999998],[83.022499999999994,41.695433000000001],[83.007728999999998,41.691218999999997]]]} {"type":"MultiLineString","coordinates":[[[83.030783,41.697861000000003],[83.029948000000005,41.697662999999999],[83.028228999999996,41.697189000000002],[83.025898999999995,41.696514000000001],[83.022717,41.695501999999998]]]} ..... ..... If there is nothing wrong with my template file xj1JSON.tmpl, the "coordinates" of GeoJSON output should match with the ST_AsGeoJSON(the_geom).I have no clue. -------------- next part -------------- An HTML attachment was scrubbed... URL: From quansheng.cs at gmail.com Wed Apr 18 02:23:21 2012 From: quansheng.cs at gmail.com (Li Quansheng) Date: Wed, 18 Apr 2012 17:23:21 +0800 Subject: [mapserver-users] mapserver 5.6 CGI output GeoJSON format In-Reply-To: References: Message-ID: Stave, you are right. Thank you very much! I add [shpxy precision="6"] then the ''coordinates" output correctely. ? 2012?4?18? ??2:58?Lime, Steve D (DNR) ??? > So the problem with the coordinates is they are truncated or ??? Not > having the spec handy what would the correct output be? There are > several arguments to the shpxy tag that will probably be of help. For > example you might add: > > [shpxy precision="6"] > > Steve > > -----Original Message----- > From: mapserver-users-bounces at lists.osgeo.org [mailto: > mapserver-users-bounces at lists.osgeo.org] On Behalf Of Li Quansheng > Sent: Tuesday, April 17, 2012 11:18 AM > To: mapserver-users at lists.osgeo.org > Subject: [mapserver-users] mapserver 5.6 CGI output GeoJSON format > > hi guys, > I installed FGS 5.6.3 on my VM to do some studying, these days I want to > add WFS layer to my applyaction via openlayers, and I want to do some WFS > query to output GeoJSON, I do my best, now,there is one problem I can't > figure out. > my mapfile: (mapserver 5.6) > .... > OUTPUTFORMAT > NAME "geojson" > DRIVER "TEMPLATE" > MIMETYPE "application/json; subtype=geojson" > FORMATOPTION "FILE=xj1JSON.tmpl" > END > ... > METADATA > 'ows_title' 'XJ-MAP' #OWS (OGC Web Services) > 'ows_onlineresource' > ' > http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map > ' > 'ows_srs' 'EPSG:4326' > 'wms_tile' 'xjmap' > 'wms_onlineresource' > ' > http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map > ' > 'wms_srs' 'EPSG:4326 EPSG:900913' > "wfs_title" "xjmap" > "wfs_onlineresource" > " > http://192.168.207.100/cgin-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map& > " > "wfs_srs" "EPSG:4326 EPSG:900913" ## Recommended > "wfs_abstract" "xjmap WFS service." ## Recommended > "wfs_enable_request" "*" # necessary,"*" enables all requests > "wfs_encoding" "UTF-8" > END > .... > LAYER > NAME 'tielu' > TYPE LINE > DUMP true > TEMPLATE fooOnlyForWMSGetFeatureInfo > EXTENT 70.409351 33.963843 99.420299 49.549665 CONNECTIONTYPE postgis > CONNECTION "host=localhost dbname=xj1 user=xxx password=xxx" > PROCESSING "CLOSE_CONNECTION=DEFER" > DATA "the_geom from tielu" > METADATA > 'ows_title' 'tielu' > "wfs_title" "tielu" ##REQUIRED > "wfs_srs" "EPSG:4326" ## REQUIRED > "wfs_featureid" "gid" > #"wfs_getfeature_formatlist" "geojson" # mapserver 6.0 support > "gml_include_items" "all" ## Optional (serves all attributes for > layer) > "gml_featureid" "gid" ## REQUIRED > "wfs_enable_request" "*" > END > STATUS OFF > TRANSPARENCY 100 > PROJECTION > 'proj=longlat' > 'datum=WGS84' > 'no_defs' > END > CLASS > NAME 'tielu' > STYLE > WIDTH 0.91 > COLOR 164 229 51 > END > END > END > .... > the GeoJson outputformat template file xj1JSON.tmpl // mapserver template > [resultset layer=tielu] { > "type": "FeatureCollection", > "features": [ > [feature limit=-1 feature trimlast=","] > { > "type": "Feature", > "id": "[gid]", > "geometry": { > "type": "MultiLineString", > "coordinates": [ > "coordinates": [[[shpxy]]] > ] > }, > "properties": { > "gid": "[gid]", > "type": "[type]", > "name": "[name]" > } > }, > [/feature] > ] > } > [/resultset] > > I want to output the "tielu" multiline layer , I can success execute the > http request, > http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qformat=geojson > , It seemed that all the GeoJSON output is perfect except the output > coordinates of the colum the_geom. > the output is as flowings: > { > "type": "FeatureCollection", > "features": [ > { > "type": "Feature", > "id": "1", > "geometry": { > "type": "MultiLineString", > "coordinates": [ > "coordinates": [[84,42 84,42 84,42 84,42 83,42 > 83,42 83,42 83,42 > 83,42 83,42]] //there is sth wrong here! > ] > }, > "properties": { > "gid": "1", > "type": "70", > "name": "name111" > } > }, > .... > ] > } > I think sth wrong in my template file about "coordinates": > [[[shpxy]]], I do many google searching,try my best to correct the file,I > try > "coordinates": [[LONG], [LAT]] etc, > , but I failed, Could anyone give me some advice, thank you very much! > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From kristian_frost7 at hotmail.com Wed Apr 18 05:47:06 2012 From: kristian_frost7 at hotmail.com (Frost89) Date: Wed, 18 Apr 2012 05:47:06 -0700 (PDT) Subject: [mapserver-users] Possible bug: Cairo/PDF output labels Message-ID: <1334753226327-4894039.post@n6.nabble.com> We're trying to output a PDF with the Cairo driver. When printing a label with ANGLE set to follow, auto or an attribute, it fails regularly. Has anyone experienced this before? A solution or workaround? /Kristian -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Possible-bug-Cairo-PDF-output-labels-tp4894039p4894039.html Sent from the Mapserver - User mailing list archive at Nabble.com. From donald.kerr at dkerr.co.uk Wed Apr 18 11:15:27 2012 From: donald.kerr at dkerr.co.uk (Donald Kerr) Date: Wed, 18 Apr 2012 19:15:27 +0100 Subject: [mapserver-users] Possible bug: Cairo/PDF output labels In-Reply-To: <1334753226327-4894039.post@n6.nabble.com> Message-ID: <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> Kristian, What kind of labels are you trying to render? Are they at specific points or offsets? Are you only getting this issue when you output as a pdf or is it the same with png or jpg? Regards, Donald -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Frost89 Sent: 18 April 2012 13:47 To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Possible bug: Cairo/PDF output labels We're trying to output a PDF with the Cairo driver. When printing a label with ANGLE set to follow, auto or an attribute, it fails regularly. Has anyone experienced this before? A solution or workaround? /Kristian -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Possible-bug-Cairo-PDF-output-labels-tp4 894039p4894039.html Sent from the Mapserver - User mailing list archive at Nabble.com. _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From kristian_frost7 at hotmail.com Thu Apr 19 00:32:59 2012 From: kristian_frost7 at hotmail.com (Frost89) Date: Thu, 19 Apr 2012 00:32:59 -0700 (PDT) Subject: [mapserver-users] RE: Possible bug: Cairo/PDF output labels In-Reply-To: <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> References: <1334753226327-4894039.post@n6.nabble.com> <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> Message-ID: <1334820779245-4897192.post@n6.nabble.com> It is a line layer with roads, and the label is the name of the roads. The problem is only when we try to output as PDF. -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Possible-bug-Cairo-PDF-output-labels-tp4894039p4897192.html Sent from the Mapserver - User mailing list archive at Nabble.com. From kristian_frost7 at hotmail.com Thu Apr 19 02:14:37 2012 From: kristian_frost7 at hotmail.com (Frost89) Date: Thu, 19 Apr 2012 02:14:37 -0700 (PDT) Subject: [mapserver-users] RE: Possible bug: Cairo/PDF output labels In-Reply-To: <1334820779245-4897192.post@n6.nabble.com> References: <1334753226327-4894039.post@n6.nabble.com> <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> <1334820779245-4897192.post@n6.nabble.com> Message-ID: <1334826877776-4897513.post@n6.nabble.com> I'll try to be a bit more specific :) Below I've posted my layers as they look in the mapfile. I'm drawing the PDF with C# MapScript in a webapplication. When debugging, I can see that it fails when calling draw() on my mapObj. It doesn't fail everytime, but most of the time. In my logfile it stop with this line: [Wed Apr 18 12:39:37 2012].327000 msDrawMap(): Drawing Label Cache, 0.000s My layers: LAYER # Streetnames CONNECTION "C:\proj\Grundkort\VEJMIDTE_syddjurs.tab" CONNECTIONTYPE ogr FILTER ("[vejnavn]" != "UDEN NAVN") GROUP "Oversigtskort" LABELITEM "vejnavn" MAXSCALEDENOM 60000 NAME "Vejnavne" STATUS on TYPE line METADATA "ows_group_title" "Oversigtskort" "ows_title" "Oversigtskort - Vejnavne" END CLASS LABEL ANGLE follow ALIGN center COLOR 0 0 0 FONT "Arial" MINDISTANCE 150 OUTLINECOLOR 255 255 255 OUTLINEWIDTH 1 POSITION cc SIZE 10 TYPE truetype END END END LAYER # Housenumbers CONNECTION "C:\proj\Grundkort\Husnr.tab" CONNECTIONTYPE ogr GROUP "Oversigtskort" LABELITEM "husnummer" MAXSCALEDENOM 2000 NAME "Husnumre" STATUS on TYPE annotation METADATA "ows_group_title" "Grundkort" "ows_title" "Grundkort - Husnumre" END CLASS LABEL ANGLE [rotation] ALIGN center COLOR 0 0 0 FONT "Arial" OUTLINECOLOR 255 255 255 OUTLINEWIDTH 1 POSITION cc SIZE 10 TYPE truetype END END END -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Possible-bug-Cairo-PDF-output-labels-tp4894039p4897513.html Sent from the Mapserver - User mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at state.mn.us Thu Apr 19 06:17:08 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Thu, 19 Apr 2012 13:17:08 +0000 Subject: [mapserver-users] RE: Possible bug: Cairo/PDF output labels In-Reply-To: <1334826877776-4897513.post@n6.nabble.com> References: <1334753226327-4894039.post@n6.nabble.com> <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> <1334820779245-4897192.post@n6.nabble.com>, <1334826877776-4897513.post@n6.nabble.com> Message-ID: If you put a constant in for the ANGLE it works? Does the rotation column contain numbers for all features? Steve ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] on behalf of Frost89 [kristian_frost7 at hotmail.com] Sent: Thursday, April 19, 2012 4:14 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] RE: Possible bug: Cairo/PDF output labels I'll try to be a bit more specific :) Below I've posted my layers as they look in the mapfile. I'm drawing the PDF with C# MapScript in a webapplication. When debugging, I can see that it fails when calling draw() on my mapObj. It doesn't fail everytime, but most of the time. In my logfile it stop with this line: [Wed Apr 18 12:39:37 2012].327000 msDrawMap(): Drawing Label Cache, 0.000s My layers: LAYER # Streetnames CONNECTION "C:\proj\Grundkort\VEJMIDTE_syddjurs.tab" CONNECTIONTYPE ogr FILTER ("[vejnavn]" != "UDEN NAVN") GROUP "Oversigtskort" LABELITEM "vejnavn" MAXSCALEDENOM 60000 NAME "Vejnavne" STATUS on TYPE line METADATA "ows_group_title" "Oversigtskort" "ows_title" "Oversigtskort - Vejnavne" END CLASS LABEL ANGLE follow ALIGN center COLOR 0 0 0 FONT "Arial" MINDISTANCE 150 OUTLINECOLOR 255 255 255 OUTLINEWIDTH 1 POSITION cc SIZE 10 TYPE truetype END END END LAYER # Housenumbers CONNECTION "C:\proj\Grundkort\Husnr.tab" CONNECTIONTYPE ogr GROUP "Oversigtskort" LABELITEM "husnummer" MAXSCALEDENOM 2000 NAME "Husnumre" STATUS on TYPE annotation METADATA "ows_group_title" "Grundkort" "ows_title" "Grundkort - Husnumre" END CLASS LABEL ANGLE [rotation] ALIGN center COLOR 0 0 0 FONT "Arial" OUTLINECOLOR 255 255 255 OUTLINEWIDTH 1 POSITION cc SIZE 10 TYPE truetype END END END ________________________________ View this message in context: RE: Possible bug: Cairo/PDF output labels Sent from the Mapserver - User mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lists at fuchsschwanzdomain.de Thu Apr 19 14:06:20 2012 From: lists at fuchsschwanzdomain.de (Sven Geggus) Date: Thu, 19 Apr 2012 21:06:20 +0000 (UTC) Subject: [mapserver-users] Trouble with spatialite layer Message-ID: Hello, I'm trying to render a spatialite layer. The spatialite file itself seems to be correct, because it can be viewed in qgis and can be dumped using ogrinfo: $ogrinfo /home/sven/osm/topo/ocean.sqlite polygons -summary INFO: Open of `ocean.sqlite' using driver `SQLite' successful. Layer name: polygons Geometry: Polygon Feature Count: 31672 Extent: (-20037508.342789, -20037508.342789) - (20037508.342789, 20037508.342789) Layer SRS WKT: PROJCS["WGS 84 / Pseudo-Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.257223563, AUTHORITY["EPSG","7030"]], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0, AUTHORITY["EPSG","8901"]], UNIT["degree",0.0174532925199433, AUTHORITY["EPSG","9122"]], AUTHORITY["EPSG","4326"]], UNIT["metre",1, AUTHORITY["EPSG","9001"]], PROJECTION["Mercator_1SP"], PARAMETER["central_meridian",0], PARAMETER["scale_factor",1], PARAMETER["false_easting",0], PARAMETER["false_northing",0], EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs"], AUTHORITY["EPSG","3857"], AXIS["X",EAST], AXIS["Y",NORTH]] FID Column = OGC_FID Geometry Column = GEOMETRY However this will not render in mapserver (6.0.1) using the following layer syntax: LAYER DEBUG 9 MAXSCALEDENOM 2000000 MINSCALEDENOM 5000 NAME "meer" TYPE POLYGON CONNECTIONTYPE ogr CONNECTION "ocean.sqlite" DATA "select GEOMETRY from polygons" STATUS ON GROUP "default" CLASS NAME "ocean" STYLE COLOR "#579ae3" END END END Because of the debug level I get the following Error message on any single feature: msOGRFileNextShape: Rejecting feature (shapeid = XXXXX, tileid=0) of incompatible type for this layer (feature wkbType 0, layer type 2) Any hint? Sven -- "Ich f?rchte mich nicht vor der R?ckkehr der Faschisten in der Maske der Faschisten, sondern vor der R?ckkehr der Faschisten in der Maske der Demokraten" (Theodor W. Adorno) /me is giggls at ircnet, http://sven.gegg.us/ on the Web From pcorti at gmail.com Thu Apr 19 15:22:12 2012 From: pcorti at gmail.com (Paolo Corti) Date: Fri, 20 Apr 2012 00:22:12 +0200 Subject: [mapserver-users] Trouble with spatialite layer In-Reply-To: References: Message-ID: On Thu, Apr 19, 2012 at 11:06 PM, Sven Geggus wrote: > > Because of the debug level I get the following Error message on any single feature: > > msOGRFileNextShape: Rejecting feature (shapeid = XXXXX, tileid=0) of incompatible type for this layer (feature wkbType 0, layer type 2) > > Any hint? > Hi maybe an invalid geometry? try to test it with the Is_Valid() SpatiaLite operator, and/or eventually try to filter it out in DATA with a where and see if layer is displayed. cheers p -- Paolo Corti Geospatial software developer web: http://www.paolocorti.net twitter: @capooti skype: capooti From Jukka.Rahkonen at mmmtike.fi Thu Apr 19 21:26:42 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Fri, 20 Apr 2012 04:26:42 +0000 Subject: [mapserver-users] Trouble with spatialite layer In-Reply-To: References: Message-ID: <84446DEF76453C439E9E97E438E13A6314AE22@suutari.haapa.mmm.fi> Hi, They are OSM ocean polygons? Can I have a small sample so I could have a try. I have also seen that Mapserver (OGR?) is too strict with data errors, usually it would be better to skip the faulty geometries errors and continue rendering. If you had Windows machine you could test fast Spatialite rendering with this Mapserver version http://hip.latuviitta.org/tiedostot/Latuviitan_nopea_ms4w.zip (preconfigured to start at port 8060) and this Spatialite database http://hip.latuviitta.org/tiedostot/OSM_Suomi_20120213.zip The latter should be dropped into \ms4w\data Be sure to have GDAL 1.9 and Mapserver from trunk if you compile Mapserver yourself. Otherwise you will not understand how fast Mapserver is with Spatialite. -Jukka Rahkonen- ________________________________________ Sven Geggus wrote: > Hello, > I'm trying to render a spatialite layer. > The spatialite file itself seems to be correct, because it can be > viewed in qgis and can be dumped using ogrinfo: > $ogrinfo /home/sven/osm/topo/ocean.sqlite polygons -summary > INFO: Open of `ocean.sqlite' > using driver `SQLite' successful. Layer name: polygons Geometry: Polygon Feature Count: 31672 Extent: (-20037508.342789, -20037508.342789) - (20037508.342789, 20037508.342789) Layer SRS WKT: PROJCS["WGS 84 / Pseudo-Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.257223563, AUTHORITY["EPSG","7030"]], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0, AUTHORITY["EPSG","8901"]], UNIT["degree",0.0174532925199433, AUTHORITY["EPSG","9122"]], AUTHORITY["EPSG","4326"]], UNIT["metre",1, AUTHORITY["EPSG","9001"]], PROJECTION["Mercator_1SP"], PARAMETER["central_meridian",0], PARAMETER["scale_factor",1], PARAMETER["false_easting",0], PARAMETER["false_northing",0], EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs"], AUTHORITY["EPSG","3857"], AXIS["X",EAST], AXIS["Y",NORTH]] FID Column = OGC_FID Geometry Column = GEOMETRY However this will not render in mapserver (6.0.1) using the following layer syntax: LAYER DEBUG 9 MAXSCALEDENOM 2000000 MINSCALEDENOM 5000 NAME "meer" TYPE POLYGON CONNECTIONTYPE ogr CONNECTION "ocean.sqlite" DATA "select GEOMETRY from polygons" STATUS ON GROUP "default" CLASS NAME "ocean" STYLE COLOR "#579ae3" END END END Because of the debug level I get the following Error message on any single feature: msOGRFileNextShape: Rejecting feature (shapeid = XXXXX, tileid=0) of incompatible type for this layer (feature wkbType 0, layer type 2) Any hint? Sven -- "Ich f?rchte mich nicht vor der R?ckkehr der Faschisten in der Maske der Faschisten, sondern vor der R?ckkehr der Faschisten in der Maske der Demokraten" (Theodor W. Adorno) /me is giggls at ircnet, http://sven.gegg.us/ on the Web _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From kristian_frost7 at hotmail.com Fri Apr 20 02:23:19 2012 From: kristian_frost7 at hotmail.com (Frost89) Date: Fri, 20 Apr 2012 02:23:19 -0700 (PDT) Subject: [mapserver-users] RE: Possible bug: Cairo/PDF output labels In-Reply-To: References: <1334753226327-4894039.post@n6.nabble.com> <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> <1334820779245-4897192.post@n6.nabble.com> <1334826877776-4897513.post@n6.nabble.com> Message-ID: <1334913799131-4901381.post@n6.nabble.com> After a quick test it seems to work with a constant of 45. This doesn't solve our prooblem though. The most important for us, is the ANGLE follow on the roads. It draws bitmaps fine, its just the PDF that fails. The build is made by Tamas Szekeres' from here: http://vbkto.dyndns.org/sdk/ vbkto.dyndns.org/sdk . The OUTPUTFORMAT is generated from code, but it would look like this: OUTPUTFORMAT NAME "WGK_PDF" DRIVER CAIRO/PDF MIMETYPE "application/x-pdf" IMAGEMODE RGB EXTENSION "pdf" TRANSPARENT OFF END -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Possible-bug-Cairo-PDF-output-labels-tp4894039p4901381.html Sent from the Mapserver - User mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From Jukka.Rahkonen at mmmtike.fi Fri Apr 20 03:50:51 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Fri, 20 Apr 2012 10:50:51 +0000 Subject: [mapserver-users] RE: Possible bug: Cairo/PDF output labels In-Reply-To: <1334913799131-4901381.post@n6.nabble.com> References: <1334753226327-4894039.post@n6.nabble.com> <2FAB764F9FDD4AED85034BC632B08F88@DELLM4500> <1334820779245-4897192.post@n6.nabble.com> <1334826877776-4897513.post@n6.nabble.com> <1334913799131-4901381.post@n6.nabble.com> Message-ID: <84446DEF76453C439E9E97E438E13A6314AEEC@suutari.haapa.mmm.fi> Hi, I have never observed such an error with the my Super easy WMS server. You seem to be on Windows so it will be easy for you to make a test install and do some comparisons. Read document http://latuviitta.org/documents/Super_easy_WMS_server.pdf first. -Jukka Rahkonen- ________________________________ Frost89 wrote: After a quick test it seems to work with a constant of 45. This doesn't solve our prooblem though. The most important for us, is the ANGLE follow on the roads. It draws bitmaps fine, its just the PDF that fails. The build is made by Tamas Szekeres' from here: vbkto.dyndns.org/sdk. The OUTPUTFORMAT is generated from code, but it would look like this: OUTPUTFORMAT NAME "WGK_PDF" DRIVER CAIRO/PDF MIMETYPE "application/x-pdf" IMAGEMODE RGB EXTENSION "pdf" TRANSPARENT OFF END ________________________________ View this message in context: RE: Possible bug: Cairo/PDF output labels Sent from the Mapserver - User mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jtaranu at firstbasesolutions.com Fri Apr 20 07:02:57 2012 From: jtaranu at firstbasesolutions.com (John Taranu) Date: Fri, 20 Apr 2012 10:02:57 -0400 Subject: [mapserver-users] On-the-fly vertical assembly of disparate tilesets using MapCache? Message-ID: <020f01cd1efe$4a38b810$deaa2830$@firstbasesolutions.com> Hello, Is there any recommended way to do multi-tileset vertical assembly in MapCache? I have the following setup: There are a number (over 30) fully seeded tile caches covering adjacent but spatially distinct areas. These tilesets were fully seeded down to the lowest level, with the seeding restricted to an irregular polygon extent. Areas beyond the edge of the polygon are not seeded at all. That is, any tiles within the dataset's rectangular extents but outside the polygon extent are not seeded. The tilesets do not refer back to a MapServer source for any requests. This means that any tile requests between the restricted extent and the polygon extent return a blank image and an HTTP 404 error. I am trying to serve the separate tile sets independently, but also combined into a single "mosaic-like" tile layer, to be rendered on the fly from the individual tilesets. The current set up has the mosaic layer in the MapCache config as a WMS source, referencing the tile caches as individual layers, looping back into itself through localhost. It looks like this: image/png LAYER1,LAYER2,LAYER3 true http://localhost/mapcache/service The problem is that if any tile in the 30 separate cache layers is missing, MapCache returns a blank tile for the mosaic layer. Is there another way of configuring a combined mosaic layer in MapCache, or does this require updates to the code? Thanks, --------------------------------------- John Taranu Senior Web Developer First Base Solutions Inc 140 Renfrew Drive, Suite 100 Markham, ON, L3R 6B3 phone: 905-477-3600 ext. 302 email: jtaranu at firstbasesolutions.com web: firstbasesolutions.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From frequens at gmail.com Fri Apr 20 14:50:34 2012 From: frequens at gmail.com (frequens) Date: Fri, 20 Apr 2012 23:50:34 +0200 Subject: [mapserver-users] pdf vector output in 6.02 Message-ID: Hi all, I am having trouble producing a high quality vector output pdf with 6.02 php mapscript (same trouble using shp2img) Cairo is enabled, the pdf file even gets created, but contains only a raster image? Pdf output is enabled: IMAGETYPE PDF and OUTPUTFORMAT NAME "pdf" DRIVER CAIRO/PDF MIMETYPE "application/x-pdf" IMAGEMODE RGB EXTENSION "pdf" END Since the mapserver documentation on pdf creation is rather archaic, any help (a stripped version of someone's mapfile?) would be appreciated! My cairo library is rather old also: 1.4.10. Might this have any influence? Many thanks in advance, frequens From Marc-Andre.Morin at dfo-mpo.gc.ca Fri Apr 20 18:39:17 2012 From: Marc-Andre.Morin at dfo-mpo.gc.ca (=?iso-8859-1?Q?Morin=2C_Marc-Andr=E9?=) Date: Fri, 20 Apr 2012 21:39:17 -0400 Subject: [mapserver-users] Projection issue with vrt file Message-ID: <33E3342755CFC844901AD4572AD514A4039E4655@lauqueex01.lau.dfo-mpo.ca> Hi All, I'm trying to add a VRT raster file (BSB chart) to my mapfile, but it doesn't work totally. In fact, all of my tiles are generated, but they have no data... No error is logged... It sounds like the projection or the transformation matrix is not well supported, or not well configured. If I put in comments the GeoTransform element, some blank tiles are shown where the lower left corner is located at the origin (0.000, 0.000). Moreover, I successfully opened that same VRT file with QGIS, and the projection is ok... A copy of my VRT file is shown just after my message... Here is a snippet of my mapfile: LAYER NAME "131701" GROUP "BSB" #EXTENT -70.980392 46.777300 -70.191770 47.279794 DATA "BSB/131701.vrt" TYPE RASTER STATUS OFF CLASS NAME 'BSB' END METADATA WMS_TITLE "BSB" WMS_SRS "EPSG:4326 EPSG:29450 EPSG:2949 EPSG:32187 EPSG:32188 EPSG:900913" END END Thanks in advance for your support, Marc-Andre --------------------- +proj=merc +lat_ts=47.166667 +datum=NAD83 +nodefs -5.3802490306424974e+006, 5.0001511315648770e+000,-1.8211665160056521e-004, 4.0492551038299361e+006,-2.5595698020313497e-004,-5.0010081232801378e+000 SC=50000,GD=NAD83,PR=MERCATOR,PP=47.166667,PI=5.000000,SP=,SK=0.000000,TA=90.000000,UN=METRES,SD=LNT,DX=5.000000,DY=5.000000 EC=RF,GD=NAR,VC=ZZZ,SC=ZZZ,PC=MC,P1=-70.582029,P2=47.166667,P3=0.0,P4=NOT_APPLICABLE,GC=GE,RM=NONE MULTIPOLYGON(((257.76284645559468 7745.7076975815671,2490.025011025306 7746.5301512821934,2492.2163879532559 7181.6425479723066,3276.1412438760321 7210.5951029770404,4429.0270760545409 6817.9091369725729,4890.9737230091405 6736.5650032022368,11250.811878184026 354.19735628215676,11251.785400765162 244.45756921568665,3537.7418346315158 244.33482436588929,3523.5069250460119 2029.8367618071302,1881.7430005409099 2028.8818991008357,1868.6640235103462 2447.8575431625686,258.92730402280057 2434.9666589315798))) SAULT-AU-COCHON ?/TO QU?BEC Palette E:\ms4w\apps\marinfo\data\BSB\131701.kap 1 -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.bonfort at gmail.com Sat Apr 21 04:05:14 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Sat, 21 Apr 2012 13:05:14 +0200 Subject: [mapserver-users] On-the-fly vertical assembly of disparate tilesets using MapCache? In-Reply-To: <020f01cd1efe$4a38b810$deaa2830$@firstbasesolutions.com> References: <020f01cd1efe$4a38b810$deaa2830$@firstbasesolutions.com> Message-ID: On Fri, Apr 20, 2012 at 16:02, John Taranu wrote: > Hello, > > > > Is there any recommended way to do multi-tileset vertical assembly in > MapCache? > > > > I have the following setup: > > > > There are a number (over 30) fully seeded tile caches covering adjacent but > spatially distinct areas.? These tilesets were fully seeded down to the > lowest level, with the seeding restricted to an irregular polygon extent. > Areas beyond the edge of the polygon are not seeded at all.? That is, any > tiles within the dataset?s rectangular extents but outside the polygon > extent are not seeded.? The tilesets do not refer back to a MapServer source > for any requests.? This means that any tile requests between the restricted > extent and the polygon extent return a blank image and an HTTP 404 error. > > > > I am trying to serve the separate tile sets independently, but also combined > into a single ?mosaic-like? tile layer, to be rendered on the fly from the > individual tilesets.??? The current set up has the mosaic layer in the > MapCache config as a WMS source, referencing the tile caches as individual > layers, looping back into itself through localhost.? ?It looks like this: > > > > ?? > > ????? > > ???????? > > ??????????? image/png > > ????????? ??LAYER1,LAYER2,LAYER3 > > ??????????? true > > ???????? > > ????? > > ????? > > ???????? http://localhost/mapcache/service > > ????? > > ?? This might be a setup leading to a deadlock on your webserver, if you ever reach your maximum number of clients. The lock in the worst case would hold until the curl getmap request initiated by mapcache times out. > > > > The problem is that if any tile in the 30 separate cache layers is missing, > MapCache returns a blank tile for the mosaic layer. > > > > Is there another way of configuring a combined mosaic layer in MapCache, or > does this require updates to the code? This would require an update to the code, to tell mapcache to return a transparent tile on a cache miss when no source is configured for the tileset. cheers, thomas > > > > Thanks, > > > > --------------------------------------- > > John Taranu > > Senior Web Developer > > First Base Solutions Inc > > 140 Renfrew Drive, Suite 100 > > Markham, ON, L3R 6B3 > > phone: 905-477-3600 ext. 302 > > email: jtaranu at firstbasesolutions.com > > web: firstbasesolutions.com > > > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From quansheng.cs at gmail.com Sat Apr 21 08:38:01 2012 From: quansheng.cs at gmail.com (Li Quansheng) Date: Sat, 21 Apr 2012 23:38:01 +0800 Subject: [mapserver-users] mapserver 5.6 CGI output GeoJSON format 2 Message-ID: hi guys,Steve A few day ago I post an item " mapserver 5.6 CGI output GeoJSON format " herein which I asked a question about mapserver CGI output GeoJSON,finally with Steve's help I got it! URL1:http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qformat=geojson. But now I want to add where-clause to prefilter,or I want set filter with CGI. The 'tielu' layer stored in postgis including these fields: gid,type,name,comment,the_geom, then I execute URL2:http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qlayer=tielu&qitem=name&qstring=namexx&qformat=geojson but the output is as same as the URL1's output, in fact the qstring, qitem don't take affect. I searched and visited http://www.osgeo.org/pipermail/mapserver-users/2003-April/042003.html and http://lists.osgeo.org/pipermail/mapserver-users/2009-August/062581.html, which are all Steve's ansewer posts. so I modified tielu layer in the mapfile as Steve's suggestion, ... METADATA 'ows_title' 'tielu' "wfs_title" "tielu" .... "qstring_validation_pattern" '^[A-Z]{2,8}$' END ... then I execute http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=itemnquery&qlayer=tielu&qitem=name&qstring=namexx&qformat=geojson, and returns the error, mapserv(): Web application error. Parameter 'qstring' value fails to validate. msValidateParameter(): Regular expression error. Parameter pattern validation failed. msEvalRegex(): Regular expression error. String failed expression test. I have to search and search, but couldn't work out. any suggestion, thans very much. -------------- next part -------------- An HTML attachment was scrubbed... URL: From warmerdam at pobox.com Sat Apr 21 11:47:11 2012 From: warmerdam at pobox.com (Frank Warmerdam) Date: Sat, 21 Apr 2012 11:47:11 -0700 Subject: [mapserver-users] Projection issue with vrt file In-Reply-To: <33E3342755CFC844901AD4572AD514A4039E4655@lauqueex01.lau.dfo-mpo.ca> References: <33E3342755CFC844901AD4572AD514A4039E4655@lauqueex01.lau.dfo-mpo.ca> Message-ID: <4F9300AF.1050902@pobox.com> On 12-04-20 06:39 PM, Morin, Marc-Andr? wrote: > Hi All, > > I'm trying to add a VRT raster file (BSB chart) to my mapfile, but it doesn't > work totally. > In fact, all of my tiles are generated, but they have no data... No error is > logged... > > It sounds like the projection or the transformation matrix is not well > supported, or not well configured. > > If I put in comments the GeoTransform element, some blank tiles are shown where > the lower left corner is located at the origin (0.000, 0.000). > > Moreover, I successfully opened that same VRT file with QGIS, and the > projection is ok... Marc-Andre, It is not clear to me why it is not working properly with mapserver, though I would encourage you to define the projection of the layer's data in the mapfile. MapServer does not pull this from the underlying file by default. I will also note that MapServer does not use the GCPs so you can ommit the GCPList chunk from the VRT file. If setting the PROJECTION block on the layer does not help, you can enable debugging to get a better idea of what chunks are being selected from the VRT file. Best regards, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://home.gdal.org/warmerda and watch the world go round - Rush | Geospatial Software Developer From i.skidoosh at gmail.com Sun Apr 22 12:13:47 2012 From: i.skidoosh at gmail.com (Annu Anurag) Date: Mon, 23 Apr 2012 00:43:47 +0530 Subject: [mapserver-users] postgis error "geom" deos not exit Message-ID: Dear everybody, I've been trying to get a shapefile displayed from my postgis database on my site. I've somehow been unable to do so. The site on opening says, "msDrawMap(): Image handling error. Failed to draw layer named 'Road'. msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: column "geom" does not exist LINE 1: select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),... ^ ". I set the debug variables on in my mapfile and it came up with this. [Sun Apr 22 00:23:48 2012].720775 msPostGISLayerOpen called: geom from asia_southern_asia_india_delhi_highway [Sun Apr 22 00:23:48 2012].721115 msPostGISLayerOpen: No connection in pool, creating a fresh one. [Sun Apr 22 00:23:48 2012].919149 msConnPoolRegister(Road,user=postgres password=***************** dbname=delhiroads host=localhost,0x91c6630) [Sun Apr 22 00:23:48 2012].961144 msPostGISLayerOpen: Got PostGIS version 10500. [Sun Apr 22 00:23:48 2012].961217 msPostGISLayerFreeItemInfo called. [Sun Apr 22 00:23:48 2012].961257 msPostGISLayerInitItemInfo called. [Sun Apr 22 00:23:48 2012].961293 msPostGISLayerWhichShapes called. [Sun Apr 22 00:23:48 2012].961335 msPostGISParseData called. [Sun Apr 22 00:23:48 2012].961397 msPostGISRetrievePK called. [Sun Apr 22 00:23:48 2012].961440 msPostGISRetrievePK: select attname from pg_attribute, pg_constraint, pg_class where pg_constraint.conrelid = pg_class.oid and pg_class.oid = pg_attribute.attrelid and pg_constraint.contype = 'p' and pg_constraint.conkey[1] = pg_attribute.attnum and pg_class.relname = 'asia_southern_asia_india_delhi_highway' and pg_table_is_visible(pg_class.oid) and pg_constraint.conkey[2] is null [Sun Apr 22 00:23:48 2012].970777 msPostGISParseData: unique_column=gid, srid=, geom_column_name=geom, table_name=asia_southern_asia_india_delhi_highway [Sun Apr 22 00:23:48 2012].970865 msPostGISBuildSQL called. [Sun Apr 22 00:23:48 2012].970899 msPostGISBuildSQLItems called. [Sun Apr 22 00:23:48 2012].970935 msPostGISBuildSQLItems: 1 items requested. [Sun Apr 22 00:23:48 2012].970966 msPostGISBuildSQLFrom called. [Sun Apr 22 00:23:48 2012].971015 msPostGISBuildSQLWhere called. [Sun Apr 22 00:23:48 2012].971045 msPostGISBuildSQLSRID called. [Sun Apr 22 00:23:48 2012].971076 msPostGISBuildSQLSRID: Building find_srid line. [Sun Apr 22 00:23:48 2012].971106 msPostGISBuildSQLSRID: Found table (asia_southern_asia_india_delhi_highway) [Sun Apr 22 00:23:48 2012].971140 msPostGISBuildSQLBox called. [Sun Apr 22 00:23:48 2012].971246 msPostGISLayerWhichShapes query: select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),'hex') as geom,"gid" from asia_southern_asia_india_delhi_highway where geom && GeomFromText('POLYGON((76.8164150612777 28.410443,76.8164150612777 28.862691,77.4196089387223 28.862691,77.4196089387223 28.410443,76.8164150612777 28.410443))',find_srid('','asia_southern_asia_india_delhi_highway','geom')) [Sun Apr 22 00:23:48 2012].974241 msPostGISLayerWhichShapes query status: PGRES_FATAL_ERROR (7) [Sun Apr 22 00:23:48 2012].974320 Error (msPostGISLayerWhichShapes() ) executing query: ERROR: column "geom" does not exist LINE 1: select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),... ^ [Sun Apr 22 00:23:48 2012].974372 msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: column "geom" does not exist LINE 1: select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),... ^ [Sun Apr 22 00:23:48 2012].974411 msPostGISLayerFreeItemInfo called. [Sun Apr 22 00:23:48 2012].974444 msPostGISLayerClose called: geom from asia_southern_asia_india_delhi_highway [Sun Apr 22 00:23:48 2012].974478 msConnPoolRelease(Road,user=postgres password=Christbearers dbname=delhiroads host=localhost,0x91c6630) [Sun Apr 22 00:23:48 2012].974510 msConnPoolClose(user=postgres password=Christbearers dbname=delhiroads host=localhost,0x91c6630) [Sun Apr 22 00:23:48 2012].975210 msDrawMap(): Image handling error. Failed to draw layer named 'Road'. [Sun Apr 22 00:23:48 2012].976675 msPostGISLayerClose called: geom from asia_southern_asia_india_delhi_highway [Sun Apr 22 00:23:48 2012].977001 freeLayer(): freeing layer at 0x91c8538. [Sun Apr 22 00:23:48 2012].977060 msPostGISLayerIsOpen called. An additional detail is that I've recently installed pgrouting onto my system. I got the deb files for the latest pgrouting package available from the ubuntu repositories. Its installed with support for driving distance. When I ran my mapfile which had been running fine using bare shapefiles, I got an error. Here is the mapfile. MAP # /////////////////////////////////////////////////////////////MAPFILE BEGINS.//////////////////////////////////////////////////////////////////////////// NAME "First" CONFIG "MS_ERRORFILE" "/var/www/tmp/ms_error.txt" CONFIG "ON_MISSING_DATA" "LOG" CONFIG "PROJ_LIB" "/usr/share/proj/" CONFIG "PROJ_DEBUG" "ON" CONFIG "CPL_DEBUG" "ON" SIZE 1024 768 IMAGECOLOR 239 245 186 IMAGETYPE PNG SHAPEPATH "/var/www/Delhi/" FONTSET /var/www/fonts/fontset.txt EXTENT 76.898503 28.410443 77.337521 28.862691 # # ///////////////////////////////////////////////////////WEB CONSTRUCT BEGINS. /////////////////////////////////////////////////////////////// # WEB TEMPLATE "/var/www/roadrefined.html" IMAGEPATH "/var/www/tmp/" IMAGEURL "/tmp/" END #__________________END OF THE WEB CONSTRUCT._____________________######################################################################## # # //////////////////////////////////////////////////////THE FIRST LAYER. LAYER THAT DRAWS EVERYTHING. /////////////////////////////////////// # LAYER NAME "Road" CONNECTIONTYPE postgis CONNECTION "user=postgres password=************** dbname=delhiroads host=localhost" DEBUG 5 STATUS DEFAULT TYPE LINE DATA "geom from asia_southern_asia_india_delhi_highway" LABELCACHE ON LABELITEM "name" # # //////////////////////////////////////////////////////THE CLASS THAT CLASSIFIES EVERYTHING IN IT. //////////////////////////////// # CLASS # # /////////////////////////////////////////////////////THE STYLE OF DRAWING THIS CLASS. //////////////////////////////////// # STYLE OUTLINECOLOR 0 123 0 COLOR 153 205 205 END #___END OF THE SYLE DECLARATION FOR THIS CLASS.___##################################################################### # # ////////////////////////////////////////////////////THE LABEL DISCIPLINE FOR THIS CLASS. //////////////////////////////// # LABEL MINFEATURESIZE auto COLOR 0 0 0 FONT "arial" TYPE truetype ANGLE follow SIZE 12 MINDISTANCE 50 REPEATDISTANCE 150 END #________END OF THE LABEL DISCIPLINE FOR THIS CLASS.________########################################################### END #_________END OF THE CLASS THAT CLASSIFIES EVERYTHING.___________############################################################## END #________END OF THE LAYER THAT DRAWS EVERYTHING._________############################################################################## END #_________________________________END OF THE MAPFILE, ATLAST.___________________________________####################################################### I'm stuck here for long and my project is stuck too. If anybody has any clue how to work this one out, please help. Anurag. -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Sun Apr 22 12:29:47 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Sun, 22 Apr 2012 15:29:47 -0400 Subject: [mapserver-users] postgis error "geom" deos not exit In-Reply-To: References: Message-ID: <4F945C2B.10101@swoodbridge.com> The issue here has to do with what you called your geometry column in the database. If you loaded the data using shp2pgsql and did not specify a geometry column name then the default is "the_geom" and not "geom" If you are not sure then check with psql like psql -U postgres -h localhost delhiroads \d asia_southern_asia_india_delhi_highway \q And look for the column name for the geometry type column. If you used mixed case names then you need to double quote the column names of the connection will fold the names to lowercase and you will not find the column. -Steve W On 4/22/2012 3:13 PM, Annu Anurag wrote: > Dear everybody, > > I've been trying to get a shapefile displayed > from my postgis database on my site. I've somehow been unable to do so. > The site on opening says, "msDrawMap(): Image handling error. Failed to > draw layer named 'Road'. msPostGISLayerWhichShapes(): Query error. Error > executing query: ERROR: column "geom" does not exist LINE 1: select > "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),... ^ ". I set the > debug variables on in my mapfile and it came up with this. > > [Sun Apr 22 00:23:48 2012].720775 msPostGISLayerOpen called: geom from > asia_southern_asia_india_delhi_highway > [Sun Apr 22 00:23:48 2012].721115 msPostGISLayerOpen: No connection in > pool, creating a fresh one. > [Sun Apr 22 00:23:48 2012].919149 msConnPoolRegister(Road,user=postgres > password=***************** dbname=delhiroads host=localhost,0x91c6630) > [Sun Apr 22 00:23:48 2012].961144 msPostGISLayerOpen: Got PostGIS > version 10500. > [Sun Apr 22 00:23:48 2012].961217 msPostGISLayerFreeItemInfo called. > [Sun Apr 22 00:23:48 2012].961257 msPostGISLayerInitItemInfo called. > [Sun Apr 22 00:23:48 2012].961293 msPostGISLayerWhichShapes called. > [Sun Apr 22 00:23:48 2012].961335 msPostGISParseData called. > [Sun Apr 22 00:23:48 2012].961397 msPostGISRetrievePK called. > [Sun Apr 22 00:23:48 2012].961440 msPostGISRetrievePK: select attname > from pg_attribute, pg_constraint, pg_class where pg_constraint.conrelid > = pg_class.oid and pg_class.oid = pg_attribute.attrelid and > pg_constraint.contype = 'p' and pg_constraint.conkey[1] = > pg_attribute.attnum and pg_class.relname = > 'asia_southern_asia_india_delhi_highway' and > pg_table_is_visible(pg_class.oid) and pg_constraint.conkey[2] is null > [Sun Apr 22 00:23:48 2012].970777 msPostGISParseData: unique_column=gid, > srid=, geom_column_name=geom, > table_name=asia_southern_asia_india_delhi_highway > [Sun Apr 22 00:23:48 2012].970865 msPostGISBuildSQL called. > [Sun Apr 22 00:23:48 2012].970899 msPostGISBuildSQLItems called. > [Sun Apr 22 00:23:48 2012].970935 msPostGISBuildSQLItems: 1 items requested. > [Sun Apr 22 00:23:48 2012].970966 msPostGISBuildSQLFrom called. > [Sun Apr 22 00:23:48 2012].971015 msPostGISBuildSQLWhere called. > [Sun Apr 22 00:23:48 2012].971045 msPostGISBuildSQLSRID called. > [Sun Apr 22 00:23:48 2012].971076 msPostGISBuildSQLSRID: Building > find_srid line. > [Sun Apr 22 00:23:48 2012].971106 msPostGISBuildSQLSRID: Found table > (asia_southern_asia_india_delhi_highway) > [Sun Apr 22 00:23:48 2012].971140 msPostGISBuildSQLBox called. > [Sun Apr 22 00:23:48 2012].971246 msPostGISLayerWhichShapes query: > select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),'hex') as > geom,"gid" from asia_southern_asia_india_delhi_highway where geom && > GeomFromText('POLYGON((76.8164150612777 28.410443,76.8164150612777 > 28.862691,77.4196089387223 28.862691,77.4196089387223 > 28.410443,76.8164150612777 > 28.410443))',find_srid('','asia_southern_asia_india_delhi_highway','geom')) > [Sun Apr 22 00:23:48 2012].974241 msPostGISLayerWhichShapes query > status: PGRES_FATAL_ERROR (7) > [Sun Apr 22 00:23:48 2012].974320 Error (msPostGISLayerWhichShapes() > ) executing query: ERROR: column "geom" does not exist > LINE 1: select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),... > ^ > [Sun Apr 22 00:23:48 2012].974372 msPostGISLayerWhichShapes(): Query > error. Error executing query: ERROR: column "geom" does not exist > LINE 1: select "name",encode(ST_AsBinary(ST_Force_2D("geom"),'NDR'),... > ^ > > [Sun Apr 22 00:23:48 2012].974411 msPostGISLayerFreeItemInfo called. > [Sun Apr 22 00:23:48 2012].974444 msPostGISLayerClose called: geom from > asia_southern_asia_india_delhi_highway > [Sun Apr 22 00:23:48 2012].974478 msConnPoolRelease(Road,user=postgres > password=Christbearers dbname=delhiroads host=localhost,0x91c6630) > [Sun Apr 22 00:23:48 2012].974510 msConnPoolClose(user=postgres > password=Christbearers dbname=delhiroads host=localhost,0x91c6630) > [Sun Apr 22 00:23:48 2012].975210 msDrawMap(): Image handling error. > Failed to draw layer named 'Road'. > [Sun Apr 22 00:23:48 2012].976675 msPostGISLayerClose called: geom from > asia_southern_asia_india_delhi_highway > [Sun Apr 22 00:23:48 2012].977001 freeLayer(): freeing layer at 0x91c8538. > [Sun Apr 22 00:23:48 2012].977060 msPostGISLayerIsOpen called. > > > An additional detail is that I've recently installed pgrouting onto my > system. I got the deb files for the latest pgrouting package available > from the ubuntu repositories. Its installed with support for driving > distance. When I ran my mapfile which had been running fine using bare > shapefiles, I got an error. Here is the mapfile. > > > MAP # > /////////////////////////////////////////////////////////////MAPFILE > BEGINS.//////////////////////////////////////////////////////////////////////////// > NAME "First" > CONFIG "MS_ERRORFILE" "/var/www/tmp/ms_error.txt" > CONFIG "ON_MISSING_DATA" "LOG" > CONFIG "PROJ_LIB" "/usr/share/proj/" > CONFIG "PROJ_DEBUG" "ON" > CONFIG "CPL_DEBUG" "ON" > SIZE 1024 768 > IMAGECOLOR 239 245 186 > IMAGETYPE PNG > SHAPEPATH "/var/www/Delhi/" > FONTSET /var/www/fonts/fontset.txt > EXTENT 76.898503 28.410443 77.337521 28.862691 > > # > # ///////////////////////////////////////////////////////WEB > CONSTRUCT BEGINS. > /////////////////////////////////////////////////////////////// > # > > WEB > TEMPLATE "/var/www/roadrefined.html" > IMAGEPATH "/var/www/tmp/" > IMAGEURL "/tmp/" > END #__________________END OF THE WEB > CONSTRUCT._____________________######################################################################## > > # > # //////////////////////////////////////////////////////THE > FIRST LAYER. LAYER THAT DRAWS EVERYTHING. > /////////////////////////////////////// > # > > LAYER > NAME "Road" > CONNECTIONTYPE postgis > CONNECTION "user=postgres password=************** > dbname=delhiroads host=localhost" > DEBUG 5 > STATUS DEFAULT > TYPE LINE > DATA "geom from asia_southern_asia_india_delhi_highway" > LABELCACHE ON > LABELITEM "name" > > # > # //////////////////////////////////////////////////////THE > CLASS THAT CLASSIFIES EVERYTHING IN IT. //////////////////////////////// > # > > CLASS > > # > # > /////////////////////////////////////////////////////THE STYLE OF > DRAWING THIS CLASS. //////////////////////////////////// > # > > STYLE > OUTLINECOLOR 0 123 0 > COLOR 153 205 205 > END #___END OF THE SYLE DECLARATION FOR THIS > CLASS.___##################################################################### > > # > # > ////////////////////////////////////////////////////THE LABEL DISCIPLINE > FOR THIS CLASS. //////////////////////////////// > # > > LABEL > MINFEATURESIZE auto > COLOR 0 0 0 > FONT "arial" > TYPE truetype > ANGLE follow > SIZE 12 > MINDISTANCE 50 > REPEATDISTANCE 150 > END #________END OF THE LABEL DISCIPLINE FOR THIS > CLASS.________########################################################### > > END #_________END OF THE CLASS THAT CLASSIFIES > EVERYTHING.___________############################################################## > END #________END OF THE LAYER THAT DRAWS > EVERYTHING._________############################################################################## > END #_________________________________END OF THE MAPFILE, > ATLAST.___________________________________####################################################### > > > > > I'm stuck here for long and my project is stuck too. If anybody has any > clue how to work this one out, please help. > > Anurag. > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From i.skidoosh at gmail.com Sun Apr 22 14:44:09 2012 From: i.skidoosh at gmail.com (Annu Anurag) Date: Mon, 23 Apr 2012 03:14:09 +0530 Subject: [mapserver-users] Re: postgis error "geom" does not exist Message-ID: Thank you very much Stephen sir. It solved my problem. The geometry column was "the_geom" instead of "geom" like you said. Thanks very much again. -------------- next part -------------- An HTML attachment was scrubbed... URL: From frequens at gmail.com Sun Apr 22 23:37:07 2012 From: frequens at gmail.com (frequens) Date: Mon, 23 Apr 2012 08:37:07 +0200 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: References: Message-ID: Weird.To add a little: With 5.6.5 I am able to get a vector pdf using mapserv or shp2img, mapscript dies without message. With 6.0.2 in all three cases (shp2img, mapserv, mapscript) the pdf gets created, yet contains only the rendered raster image of the vector layers. Why this fallback to raster rendering, is this something supposed to happen? All the underlying libraries are the same. Any hints? BR frequens On Fri, Apr 20, 2012 at 11:50 PM, frequens wrote: > Hi all, > > I am having trouble producing a high quality vector output pdf with > 6.02 php mapscript (same trouble using shp2img) > Cairo is enabled, the pdf file even gets created, but contains only a > raster image? > > Pdf output is enabled: > IMAGETYPE PDF > ?and > OUTPUTFORMAT > ?NAME "pdf" > ?DRIVER CAIRO/PDF > ?MIMETYPE "application/x-pdf" > ?IMAGEMODE RGB > ?EXTENSION "pdf" > END > > Since the mapserver documentation on pdf creation is rather archaic, > any help (a stripped version of someone's mapfile?) would be > appreciated! > My cairo library is rather old also: 1.4.10. Might this have any influence? > > Many thanks in advance, > > frequens From Jukka.Rahkonen at mmmtike.fi Mon Apr 23 00:17:58 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Mon, 23 Apr 2012 07:17:58 +0000 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: References: Message-ID: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> Hi, PDF output works for me on Windows (MS4W) but I seem to have problems with Linux and Mapserver 6.0.1 also. This one gives HTTP 500 Internal error message and on the server side there seems to occur a segfault http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=469&HEIGHT=354&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=385063.18278820685,6671589.90189085,385461.47239845013,6671890.529869583&SRS=EPSG:3067&STYLES= Same with SVG output. Png etc. works fine. I have the same outputformat as you. -Jukka Rahkonen- frequens wrote: > > Weird.To add a little: > With 5.6.5 I am able to get a vector pdf using mapserv or shp2img, > mapscript dies without message. > With 6.0.2 in all three cases (shp2img, mapserv, mapscript) the pdf > gets created, yet contains only the rendered raster image of the > vector layers. > Why this fallback to raster rendering, is this something supposed to > happen? All the underlying libraries are the same. > > Any hints? > > BR > > frequens > > On Fri, Apr 20, 2012 at 11:50 PM, frequens wrote: > > Hi all, > > > > I am having trouble producing a high quality vector output pdf with > > 6.02 php mapscript (same trouble using shp2img) > > Cairo is enabled, the pdf file even gets created, but > contains only a > > raster image? > > > > Pdf output is enabled: > > IMAGETYPE PDF > > ?and > > OUTPUTFORMAT > > ?NAME "pdf" > > ?DRIVER CAIRO/PDF > > ?MIMETYPE "application/x-pdf" > > ?IMAGEMODE RGB > > ?EXTENSION "pdf" > > END > > > > Since the mapserver documentation on pdf creation is rather archaic, > > any help (a stripped version of someone's mapfile?) would be > > appreciated! > > My cairo library is rather old also: 1.4.10. Might this > have any influence? > > > > Many thanks in advance, > > > > frequens > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From Keith.Moss at landgate.wa.gov.au Mon Apr 23 00:20:11 2012 From: Keith.Moss at landgate.wa.gov.au (Keith Moss) Date: Mon, 23 Apr 2012 00:20:11 -0700 (PDT) Subject: [mapserver-users] owsRequestObj->loadParams() in PHP/MapScript Message-ID: <1335165611124-4909407.post@n6.nabble.com> Hi all, I was just wondering if anyone's had any luck getting PHP/MapScript's owsRequestObj->loadParams() to process HTTP POST requests (i.e. for WFS GetFeature calls) when PHP/MapScript is loaded as a PHP module? r9950 (http://www.osgeo.org/pipermail//mapserver-commits/2010-March/002659.html) from last year sounds to me like it should fix up the issue, but I'm unable get it to work. Calling $request = ms_newowsrequestobj(); $request->loadParams(); fails to populate $request ($request->numparams == -1). Cheers, Keith -- View this message in context: http://osgeo-org.1560.n6.nabble.com/owsRequestObj-loadParams-in-PHP-MapScript-tp4909407p4909407.html Sent from the Mapserver - User mailing list archive at Nabble.com. From thomas.bonfort at gmail.com Mon Apr 23 00:25:38 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Mon, 23 Apr 2012 09:25:38 +0200 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> References: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> Message-ID: Can you provide a backtrace ? -- thomas On Mon, Apr 23, 2012 at 09:17, Rahkonen Jukka wrote: > Hi, > > PDF output works for me on Windows (MS4W) but I seem to have problems with Linux and Mapserver 6.0.1 also. This one gives HTTP 500 Internal error message and on the server side there seems to occur a segfault > > http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=469&HEIGHT=354&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=385063.18278820685,6671589.90189085,385461.47239845013,6671890.529869583&SRS=EPSG:3067&STYLES= > > Same with SVG output. Png etc. works fine. ?I have the same outputformat as you. > > -Jukka Rahkonen- > > frequens wrote: >> >> Weird.To add a little: >> With 5.6.5 I am able to get a vector pdf using mapserv or shp2img, >> mapscript dies without message. >> With 6.0.2 in all three cases (shp2img, mapserv, mapscript) the pdf >> gets created, yet contains only the rendered raster image of the >> vector layers. >> Why this fallback to raster rendering, is this something supposed to >> happen? All the underlying libraries are the same. >> >> Any hints? >> >> BR >> >> frequens >> >> On Fri, Apr 20, 2012 at 11:50 PM, frequens wrote: >> > Hi all, >> > >> > I am having trouble producing a high quality vector output pdf with >> > 6.02 php mapscript (same trouble using shp2img) >> > Cairo is enabled, the pdf file even gets created, but >> contains only a >> > raster image? >> > >> > Pdf output is enabled: >> > IMAGETYPE PDF >> > ?and >> > OUTPUTFORMAT >> > ?NAME "pdf" >> > ?DRIVER CAIRO/PDF >> > ?MIMETYPE "application/x-pdf" >> > ?IMAGEMODE RGB >> > ?EXTENSION "pdf" >> > END >> > >> > Since the mapserver documentation on pdf creation is rather archaic, >> > any help (a stripped version of someone's mapfile?) would be >> > appreciated! >> > My cairo library is rather old also: 1.4.10. Might this >> have any influence? >> > >> > Many thanks in advance, >> > >> > frequens >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From frequens at gmail.com Mon Apr 23 00:44:31 2012 From: frequens at gmail.com (frequens) Date: Mon, 23 Apr 2012 09:44:31 +0200 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: References: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> Message-ID: Thanks, so it looks like overall trouble...not that it solves my problem To add, I get no 500 errors in 6.0.2, mapserv/mapscript Also svg's get created, yet only have a png image inserted, no vectors. BR frequens On Mon, Apr 23, 2012 at 9:42 AM, frequens wrote: > Thanks, so it looks like overall trouble...not that it solves my problem > > To add, I get no 500 errors in 6.0.2, mapserv/mapscript > Also svg's get created, yet only have a png image inserted, no vectors. > > BR > > frequens > > On Mon, Apr 23, 2012 at 9:17 AM, Rahkonen Jukka > wrote: >> Hi, >> >> PDF output works for me on Windows (MS4W) but I seem to have problems with Linux and Mapserver 6.0.1 also. This one gives HTTP 500 Internal error message and on the server side there seems to occur a segfault >> >> http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=469&HEIGHT=354&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=385063.18278820685,6671589.90189085,385461.47239845013,6671890.529869583&SRS=EPSG:3067&STYLES= >> >> Same with SVG output. Png etc. works fine. ?I have the same outputformat as you. >> >> -Jukka Rahkonen- >> >> frequens wrote: >>> >>> Weird.To add a little: >>> With 5.6.5 I am able to get a vector pdf using mapserv or shp2img, >>> mapscript dies without message. >>> With 6.0.2 in all three cases (shp2img, mapserv, mapscript) the pdf >>> gets created, yet contains only the rendered raster image of the >>> vector layers. >>> Why this fallback to raster rendering, is this something supposed to >>> happen? All the underlying libraries are the same. >>> >>> Any hints? >>> >>> BR >>> >>> frequens >>> >>> On Fri, Apr 20, 2012 at 11:50 PM, frequens wrote: >>> > Hi all, >>> > >>> > I am having trouble producing a high quality vector output pdf with >>> > 6.02 php mapscript (same trouble using shp2img) >>> > Cairo is enabled, the pdf file even gets created, but >>> contains only a >>> > raster image? >>> > >>> > Pdf output is enabled: >>> > IMAGETYPE PDF >>> > ?and >>> > OUTPUTFORMAT >>> > ?NAME "pdf" >>> > ?DRIVER CAIRO/PDF >>> > ?MIMETYPE "application/x-pdf" >>> > ?IMAGEMODE RGB >>> > ?EXTENSION "pdf" >>> > END >>> > >>> > Since the mapserver documentation on pdf creation is rather archaic, >>> > any help (a stripped version of someone's mapfile?) would be >>> > appreciated! >>> > My cairo library is rather old also: 1.4.10. Might this >>> have any influence? >>> > >>> > Many thanks in advance, >>> > >>> > frequens >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users From havard.tveite at umb.no Mon Apr 23 01:03:26 2012 From: havard.tveite at umb.no (Havard Tveite) Date: Mon, 23 Apr 2012 10:03:26 +0200 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> References: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> Message-ID: <4F950CCE.70407@umb.no> Seems to work here. I get vector PDF output using 6.0.2 on Debian. H?vard On 4/23/2012 9:17 AM, Rahkonen Jukka wrote: > Hi, > > PDF output works for me on Windows (MS4W) but I seem to have problems with Linux and Mapserver 6.0.1 also. This one gives HTTP 500 Internal error message and on the server side there seems to occur a segfault > > http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=469&HEIGHT=354&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=385063.18278820685,6671589.90189085,385461.47239845013,6671890.529869583&SRS=EPSG:3067&STYLES= > > Same with SVG output. Png etc. works fine. I have the same outputformat as you. > > -Jukka Rahkonen- > > frequens wrote: >> >> Weird.To add a little: >> With 5.6.5 I am able to get a vector pdf using mapserv or shp2img, >> mapscript dies without message. >> With 6.0.2 in all three cases (shp2img, mapserv, mapscript) the pdf >> gets created, yet contains only the rendered raster image of the >> vector layers. >> Why this fallback to raster rendering, is this something supposed to >> happen? All the underlying libraries are the same. >> >> Any hints? >> >> BR >> >> frequens >> >> On Fri, Apr 20, 2012 at 11:50 PM, frequens wrote: >>> Hi all, >>> >>> I am having trouble producing a high quality vector output pdf with >>> 6.02 php mapscript (same trouble using shp2img) >>> Cairo is enabled, the pdf file even gets created, but >> contains only a >>> raster image? >>> >>> Pdf output is enabled: >>> IMAGETYPE PDF >>> and >>> OUTPUTFORMAT >>> NAME "pdf" >>> DRIVER CAIRO/PDF >>> MIMETYPE "application/x-pdf" >>> IMAGEMODE RGB >>> EXTENSION "pdf" >>> END >>> >>> Since the mapserver documentation on pdf creation is rather archaic, >>> any help (a stripped version of someone's mapfile?) would be >>> appreciated! >>> My cairo library is rather old also: 1.4.10. Might this >> have any influence? >>> >>> Many thanks in advance, >>> >>> frequens >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- H?vard Tveite Department of Mathematical Sciences and Technology, UMB Dr?bakveien 31, POBox 5003, N-1432 ?s, NORWAY Phone: +47 64965483 Fax: +47 64965401 http://www.umb.no/imt/ From Jukka.Rahkonen at mmmtike.fi Mon Apr 23 02:00:38 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Mon, 23 Apr 2012 09:00:38 +0000 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: References: Message-ID: <84446DEF76453C439E9E97E438E13A6314B3CF@suutari.haapa.mmm.fi> Hi, PDF output of Mapserver 6.0.1 on Linux actually works but it is sensitive to some issues in the source data. It may have something to do with topology errors in polygons but I am not sure. From another place the output is OK http://188.64.1.61/cgi-bin/osm-mapserver_i?REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=469&HEIGHT=354&LAYERS=default&TRANSPARENT=TRUE&FORMAT=application/x-pdf&BBOX=383512.485926151,6677396.947423564,383910.77553639427,6677697.575402298&SRS=EPSG:3067&STYLES= -Jukka Rahkonen- > -----Alkuper?inen viesti----- > L?hett?j?: mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] Puolesta frequens > L?hetetty: 23. huhtikuuta 2012 9:37 > Vastaanottaja: mapserver-users at lists.osgeo.org > Aihe: [mapserver-users] Re: pdf vector output in 6.02 > > Weird.To add a little: > With 5.6.5 I am able to get a vector pdf using mapserv or shp2img, > mapscript dies without message. > With 6.0.2 in all three cases (shp2img, mapserv, mapscript) the pdf > gets created, yet contains only the rendered raster image of the > vector layers. > Why this fallback to raster rendering, is this something supposed to > happen? All the underlying libraries are the same. > > Any hints? > > BR > > frequens > > On Fri, Apr 20, 2012 at 11:50 PM, frequens wrote: > > Hi all, > > > > I am having trouble producing a high quality vector output pdf with > > 6.02 php mapscript (same trouble using shp2img) > > Cairo is enabled, the pdf file even gets created, but > contains only a > > raster image? > > > > Pdf output is enabled: > > IMAGETYPE PDF > > ?and > > OUTPUTFORMAT > > ?NAME "pdf" > > ?DRIVER CAIRO/PDF > > ?MIMETYPE "application/x-pdf" > > ?IMAGEMODE RGB > > ?EXTENSION "pdf" > > END > > > > Since the mapserver documentation on pdf creation is rather archaic, > > any help (a stripped version of someone's mapfile?) would be > > appreciated! > > My cairo library is rather old also: 1.4.10. Might this > have any influence? > > > > Many thanks in advance, > > > > frequens > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From juanma.mr at gmail.com Mon Apr 23 06:39:16 2012 From: juanma.mr at gmail.com (Juanma M. R.) Date: Mon, 23 Apr 2012 15:39:16 +0200 Subject: [mapserver-users] pointObj->project behaviour differences from 4.10 to 5.6 versions In-Reply-To: References: Message-ID: Hi, I have been doing more tests to try to identify exactly the problem and I ahve realized that, according to http://twcc.free.fr/, the coordinates returned when working with php_mapscript from version 4.10 are not correct. I am trying to get where is the problem, so that I can decide wether sorting out a The issue is that the function project returns different things depending on the server configuration: Input coordinates in Google Spherical Mercator: (-20500513.477395,-3641436. 715144) Server 1: proj 4.1.5 and MapServer 4.10 returns (-90270074.105905,-216622133.8792) Server 2: proj 4.1.7 and MapServer 5.6 returns (-20500513.477395,-3641436.715144) The World Coordinate Converter automatically transform the output CRS to UTM 60S, so I can't not validate the transformation with it. The issue is that I would like to understand the expected behaviour from this function, so that I can go on checking it and defining the best way to support the functionality or detecting a problem in servers configuration. The code is as follows: function project($x, $y, $srsIn, $srsOut) { $pointObj=ms_newPointObj(); $pointObj->setXY($x,$y); $pointObj->project(ms_newProjectionObj("init=".strtolower($srsIn)), ms_newProjectionObj("init=".strtolower($srsOut))); $xout=$pointObj->x; $yout=$pointObj->y; $pointObj->free(); return $xout.",".$yout; } ?> 2012/4/16 Lime, Steve D (DNR) > The transformation is done in place, I?ve not had problems with it. What > language? Can you post a code snippet?**** > > ** ** > > *From:* mapserver-users-bounces at lists.osgeo.org [mailto: > mapserver-users-bounces at lists.osgeo.org] *On Behalf Of *Juanma M. R. > *Sent:* Thursday, April 12, 2012 4:13 AM > *To:* mapserver-users at lists.osgeo.org > *Subject:* [mapserver-users] pointObj->project behaviour differences from > 4.10 to 5.6 versions**** > > ** ** > > Dear list, > > I have a webgis application working with different CRS all over the world. > I have realized that the behaviour from version 4.10 of the function > pointObj->project differs from the one of version 5.6 from Mapserver. For > example, I try to convert (-116,-15) in 4326 and in mapscript from version > 4.10 it returns (-26158630.407638,-25040425.679281) when passing to 32630. > On the other hand, in version 5.6 of mapscript it returns the original > coordinates without transforming them. > > Is this intended or am I doing something wrong? Which is the intended > behaviour of project function in MapServer 5.6? > > Best regards, > -- > Juan Manuel Moreno Rivera. > University of Castilla-La Mancha > Albacete, Spain**** > -- Juan Manuel Moreno Rivera. University of Castilla-La Mancha Albacete, Spain -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Mon Apr 23 06:55:51 2012 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 23 Apr 2012 10:55:51 -0300 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: <4F955E67.3000508@gatewaygeomatics.com> References: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> <4F955E67.3000508@gatewaygeomatics.com> Message-ID: <4F955F67.7050905@gatewaygeomatics.com> On 12-04-23 10:51 AM, Jeff McKenna wrote: > On 12-04-23 4:17 AM, Rahkonen Jukka wrote: >> Hi, >> >> PDF output works for me on Windows (MS4W) but I seem to have problems with Linux and Mapserver 6.0.1 also. > > Always nice to hear positive feedback on MS4W, even if this was > indirect. I spent a lot of time building and testing libPoppler (for > pdf output) when adding it into a recent version of MS4W (3.0.3). Thanks. > I guess this was for PDF read support through GDAL - well carry on anyway :) -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ From jmckenna at gatewaygeomatics.com Mon Apr 23 06:51:35 2012 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 23 Apr 2012 10:51:35 -0300 Subject: [mapserver-users] Re: pdf vector output in 6.02 In-Reply-To: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> References: <84446DEF76453C439E9E97E438E13A6314B336@suutari.haapa.mmm.fi> Message-ID: <4F955E67.3000508@gatewaygeomatics.com> On 12-04-23 4:17 AM, Rahkonen Jukka wrote: > Hi, > > PDF output works for me on Windows (MS4W) but I seem to have problems with Linux and Mapserver 6.0.1 also. Always nice to hear positive feedback on MS4W, even if this was indirect. I spent a lot of time building and testing libPoppler (for pdf output) when adding it into a recent version of MS4W (3.0.3). Thanks. -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ From melanie.poser-hartmann at muenchen.de Mon Apr 23 07:05:51 2012 From: melanie.poser-hartmann at muenchen.de (melanie.poser-hartmann at muenchen.de) Date: Mon, 23 Apr 2012 16:05:51 +0200 Subject: [mapserver-users] Problem with gif lib when compiling mapserver 6.0.2 Message-ID: <4F9561BF.4030906@muenchen.de> Hello, When compiling mapserver 6.0.2 with --with-httpd=/usr/local/apache2/bin/httpd \ --with-fastcgi=/usr/local/fastcgi-2.4.0 \ --with-curl-config=/usr/local/bin/curl-config \ --with-wmsclient \ --with-wfs \ --with-wfsclient \ --with-gd=/usr/local \ --with-jpeg=/usr/local \ --with-png=/usr/local \ --with-zlib=/usr/local \ --with-freetype=/usr/local/bin/freetype-config \ --with-threads \ --with-gdal=/usr/local/gdal-1.8.0/bin/gdal-config \ --with-ogr=/usr/local/gdal-1.8.0/bin/gdal-config \ --with-proj=/usr/local/proj-4.7.0 \ --with-postgis=/usr/local/pgsql/bin/pg_config \ --with-oraclespatial=/data/ora/11.2_32 \ --with-php=/usr/local/php-5.3.5 \ *--with-gif=/usr/local/include* I receive the error configure: error: cannot find gif lib in /usr/local/include Even if there is a gif_lib.h in this directory I have Solaris 10 System , and I have installed the SMClibungif Any Ideas? Is there a --without-gif ? We do not need it. Thanks a lot Melanie -- Mit freundlichen Gruessen Melanie Poser-Hartmann Referat fuer Gesundheit und Umwelt RL - Stabstelle IT diKA Serverdienste Infrastrukturplattformen RGU-RL-diKA-SI Bayerstr. 28a 80335 Muenchen Telefon: +49 - 89 - 233 - 4 76 65 Telefax: +49 - 89 - 233 - 4 76 62 Mailbuero: s-iuk-si.rgu at muenchen.de Elektronische Kommunikation mit der Landeshauptstadt Muenchen: http://www.muenchen.de/ekomm -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.bonfort at gmail.com Mon Apr 23 07:14:26 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Mon, 23 Apr 2012 16:14:26 +0200 Subject: [mapserver-users] Problem with gif lib when compiling mapserver 6.0.2 In-Reply-To: <4F9561BF.4030906@muenchen.de> References: <4F9561BF.4030906@muenchen.de> Message-ID: try with /usr/local alone -- thomas On Mon, Apr 23, 2012 at 16:05, wrote: > Hello, > > When compiling mapserver 6.0.2 with > > --with-httpd=/usr/local/apache2/bin/httpd \ > --with-fastcgi=/usr/local/fastcgi-2.4.0 \ > --with-curl-config=/usr/local/bin/curl-config \ > --with-wmsclient \ > --with-wfs \ > --with-wfsclient \ > --with-gd=/usr/local \ > --with-jpeg=/usr/local \ > --with-png=/usr/local \ > --with-zlib=/usr/local \ > --with-freetype=/usr/local/bin/freetype-config \ > --with-threads \ > --with-gdal=/usr/local/gdal-1.8.0/bin/gdal-config \ > --with-ogr=/usr/local/gdal-1.8.0/bin/gdal-config \ > --with-proj=/usr/local/proj-4.7.0 \ > --with-postgis=/usr/local/pgsql/bin/pg_config \ > --with-oraclespatial=/data/ora/11.2_32 \ > --with-php=/usr/local/php-5.3.5 \ > --with-gif=/usr/local/include > > > > I receive the error > > configure: error: cannot find gif lib in /usr/local/include > > Even if there is a gif_lib.h in this directory > > I have Solaris 10 System , and I have installed the SMClibungif > > Any Ideas? > > Is there a --without-gif ? We do not need it. > > Thanks a lot > > Melanie > > -- > Mit freundlichen Gruessen > > Melanie Poser-Hartmann > > Referat fuer Gesundheit und Umwelt > RL - Stabstelle IT diKA > Serverdienste Infrastrukturplattformen > RGU-RL-diKA-SI > Bayerstr. 28a > 80335 Muenchen > > Telefon: +49 - 89 - 233 - 4 76 65 > Telefax: +49 - 89 - 233 - 4 76 62 > Mailbuero: s-iuk-si.rgu at muenchen.de > > Elektronische Kommunikation mit der Landeshauptstadt Muenchen: > http://www.muenchen.de/ekomm > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From francesco.dalesio at r3-gis.com Mon Apr 23 08:41:16 2012 From: francesco.dalesio at r3-gis.com (Francesco D'Alesio) Date: Mon, 23 Apr 2012 17:41:16 +0200 Subject: [mapserver-users] Mapserver 5.6, WMS client does not keep layer opacity Message-ID: <4F95781C.3070102@r3-gis.com> Hi all, I created a "merge" service for mapserver that, given some WMS getmap requests, builds a geotiff merging together WMS getmap responses. It creates an "on-the-fly" mapfile, with a LAYER CONNECTIONTYPE WMS for each layer. Everything works, except layers with OPACITY: while the getmap response (agg png 8bit) is correctly opaque (features are semi-trasparent), in the geotiff image they are not opaque anymore. Trasparency is kept (where there's no features, I can see layers under), but opacity is not (features are no more semi-trasparent and they cover layers under). Also, if I try to merge getmap responses using PHP/GD, features remain correctly opaque. Have you got any idea about why mapserver is modifying opacity while merging? Is there a way to avoid this? Thank you Regards Francesco -- From dmorissette at mapgears.com Mon Apr 23 11:03:20 2012 From: dmorissette at mapgears.com (Daniel Morissette) Date: Mon, 23 Apr 2012 14:03:20 -0400 Subject: [mapserver-users] pointObj->project behaviour differences from 4.10 to 5.6 versions In-Reply-To: References: Message-ID: <4F959968.3040204@mapgears.com> EPSG:32630 is UTM Zone 30N ... http://spatialreference.org/ref/epsg/32630/ A UTM coordinate system is defined for a limited area, a UTM zone has a width of 6 degrees of longitude, in this case EPSG:32630 WGS 84 / UTM zone 30N WGS84 Bounds: -6.0000, 0.0000, 0.0000, 84.0000 It is very likely that you are getting random values from various PROJ versions because your -116, -15 test coordinate is outside of the area of validity of the EPSG:32630 coordinate system. Daniel On 12-04-23 9:39 AM, Juanma M. R. wrote: > Hi, > > I have been doing more tests to try to identify exactly the problem and > I ahve realized that, according to http://twcc.free.fr/, the coordinates > returned when working with php_mapscript from version 4.10 are not > correct. I am trying to get where is the problem, so that I can decide > wether sorting out a The issue is that the function project returns > different things depending on the server configuration: > > Input coordinates in Google Spherical Mercator: > (-20500513.477395,-3641436. > 715144) > > Server 1: proj 4.1.5 and MapServer 4.10 returns > (-90270074.105905,-216622133.8792) > Server 2: proj 4.1.7 and MapServer 5.6 returns > (-20500513.477395,-3641436.715144) > The World Coordinate Converter automatically transform the output CRS to > UTM 60S, so I can't not validate the transformation with it. > > The issue is that I would like to understand the expected behaviour from > this function, so that I can go on checking it and defining the best way > to support the functionality or detecting a problem in servers > configuration. > > The code is as follows: > > function project($x, $y, $srsIn, $srsOut) > { > $pointObj=ms_newPointObj(); > > $pointObj->setXY($x,$y); > > > $pointObj->project(ms_newProjectionObj("init=".strtolower($srsIn)), > ms_newProjectionObj("init=".strtolower($srsOut))); > > $xout=$pointObj->x; > $yout=$pointObj->y; > > $pointObj->free(); > > return $xout.",".$yout; > } > ?> > > > 2012/4/16 Lime, Steve D (DNR) > > > The transformation is done in place, I?ve not had problems with it. > What language? Can you post a code snippet?____ > > __ __ > > *From:*mapserver-users-bounces at lists.osgeo.org > > [mailto:mapserver-users-bounces at lists.osgeo.org > ] *On Behalf Of > *Juanma M. R. > *Sent:* Thursday, April 12, 2012 4:13 AM > *To:* mapserver-users at lists.osgeo.org > > *Subject:* [mapserver-users] pointObj->project behaviour differences > from 4.10 to 5.6 versions____ > > __ __ > > Dear list, > > I have a webgis application working with different CRS all over the > world. I have realized that the behaviour from version 4.10 of the > function pointObj->project differs from the one of version 5.6 from > Mapserver. For example, I try to convert (-116,-15) in 4326 and in > mapscript from version 4.10 it returns > (-26158630.407638,-25040425.679281) when passing to 32630. On the > other hand, in version 5.6 of mapscript it returns the original > coordinates without transforming them. > > Is this intended or am I doing something wrong? Which is the > intended behaviour of project function in MapServer 5.6? > > Best regards, > -- > Juan Manuel Moreno Rivera. > University of Castilla-La Mancha > Albacete, Spain____ > > > > > -- > Juan Manuel Moreno Rivera. > University of Castilla-La Mancha > Albacete, Spain > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -- Daniel Morissette http://www.mapgears.com/ Provider of Professional MapServer Support since 2000 From donald.kerr at dkerr.co.uk Mon Apr 23 12:27:17 2012 From: donald.kerr at dkerr.co.uk (Donald Kerr) Date: Mon, 23 Apr 2012 20:27:17 +0100 Subject: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 In-Reply-To: <277AE04D44E34279BC4528EE059D9AF3@DELLM4500> Message-ID: <228817E0FFC546E9997EE71889CE699E@DELLM4500> Can anyone give me an idea of timescales for the release of PostGIS 2.0.0 support in Mapserver and then MS4W please? Many thanks. Regards, Donald From donald.kerr at dkerr.co.uk Mon Apr 23 13:46:26 2012 From: donald.kerr at dkerr.co.uk (Donald Kerr) Date: Mon, 23 Apr 2012 21:46:26 +0100 Subject: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 In-Reply-To: Message-ID: <63F6454C5D67449EA1895BD764B41D6D@DELLM4500> John, I've just installed PostGIS 2.0.0 and I'm getting: ------------------------------------ msDrawMap(): Image handling error. Failed to draw layer named 'ABC'. msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: function geomfromtext(unknown, integer) does not exist LINE 1: ...as geom,"toid" from ABC where geom && GeomFromTe... ^ HINT: No function matches the given name and argument types. You might need to add explicit type casts. ------------------------------------ >From what I can make out, it appears that "geomfromtext" has changed name in PostGIS to "ST_GeomFromText". I think "geomfromtext" is hard codeed in MapServer version 6.0.2 (MS4W 3.0.4). Many thanks. Regards, Donald -----Original Message----- From: John Callahan [mailto:john.callahan at udel.edu] Sent: 23 April 2012 21:23 To: Donald Kerr Subject: Re: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 I've been using MS4W for a while and the latest versions seem to support Postgis 2.0 just fine. - John *********************************************** John Callahan, Research Scientist Delaware Geological Survey, University of Delaware URL: http://www.dgs.udel.edu ************************************************* On Mon, Apr 23, 2012 at 3:27 PM, Donald Kerr wrote: Can anyone give me an idea of timescales for the release of PostGIS 2.0.0 support in Mapserver and then MS4W please? Many thanks. Regards, Donald _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From bfraser at geoanalytic.com Mon Apr 23 13:52:12 2012 From: bfraser at geoanalytic.com (Brent Fraser) Date: Mon, 23 Apr 2012 14:52:12 -0600 Subject: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 In-Reply-To: <63F6454C5D67449EA1895BD764B41D6D@DELLM4500> References: <63F6454C5D67449EA1895BD764B41D6D@DELLM4500> Message-ID: <4F95C0FC.5080700@geoanalytic.com> https://github.com/mapserver/mapserver/issues/4186 Best Regards, Brent Fraser On 4/23/2012 2:46 PM, Donald Kerr wrote: > John, > > I've just installed PostGIS 2.0.0 and I'm getting: > > ------------------------------------ > msDrawMap(): Image handling error. Failed to draw layer named 'ABC'. > msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: > function geomfromtext(unknown, integer) does not exist LINE 1: ...as > geom,"toid" from ABC where geom&& GeomFromTe... ^ HINT: No function matches > the given name and argument types. You might need to add explicit type > casts. > ------------------------------------ > > > From what I can make out, it appears that "geomfromtext" has changed name in > PostGIS to "ST_GeomFromText". I think "geomfromtext" is hard codeed in > MapServer version 6.0.2 (MS4W 3.0.4). > > Many thanks. > > Regards, > > Donald > > -----Original Message----- > From: John Callahan [mailto:john.callahan at udel.edu] > Sent: 23 April 2012 21:23 > To: Donald Kerr > Subject: Re: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 > > > I've been using MS4W for a while and the latest versions seem to support > Postgis 2.0 just fine. > > > - John > > > *********************************************** > John Callahan, Research Scientist > Delaware Geological Survey, University of Delaware > URL: http://www.dgs.udel.edu > ************************************************* > > > > > On Mon, Apr 23, 2012 at 3:27 PM, Donald Kerr > wrote: > > Can anyone give me an idea of timescales for the release of PostGIS 2.0.0 > support in Mapserver and then MS4W please? > > Many thanks. > > Regards, > > Donald > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From donald.kerr at dkerr.co.uk Mon Apr 23 13:56:54 2012 From: donald.kerr at dkerr.co.uk (Donald Kerr) Date: Mon, 23 Apr 2012 21:56:54 +0100 Subject: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 In-Reply-To: <4F95C0FC.5080700@geoanalytic.com> Message-ID: <31A1F8A8E8D94392B9ABEDB0639DAC03@DELLM4500> Thanks, Brent. That answers the question. Will look at using "legacy.sql" on the PostGIS side rather than reverting to an older version until such times as Mapserver/MS4W catches up. Many thanks. Regards, Donald -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Brent Fraser Sent: 23 April 2012 21:52 To: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 https://github.com/mapserver/mapserver/issues/4186 Best Regards, Brent Fraser On 4/23/2012 2:46 PM, Donald Kerr wrote: > John, > > I've just installed PostGIS 2.0.0 and I'm getting: > > ------------------------------------ > msDrawMap(): Image handling error. Failed to draw layer named 'ABC'. > msPostGISLayerWhichShapes(): Query error. Error executing query: > ERROR: function geomfromtext(unknown, integer) does not exist LINE 1: > ...as geom,"toid" from ABC where geom&& GeomFromTe... ^ HINT: No > function matches the given name and argument types. You might need to > add explicit type casts. > ------------------------------------ > > > From what I can make out, it appears that "geomfromtext" has changed > > name in > PostGIS to "ST_GeomFromText". I think "geomfromtext" is hard codeed in > MapServer version 6.0.2 (MS4W 3.0.4). > > Many thanks. > > Regards, > > Donald > > -----Original Message----- > From: John Callahan [mailto:john.callahan at udel.edu] > Sent: 23 April 2012 21:23 > To: Donald Kerr > Subject: Re: [mapserver-users] Mapserver MS4W PostGIS 2.0.0 > > > I've been using MS4W for a while and the latest versions seem to > support Postgis 2.0 just fine. > > > - John > > > *********************************************** > John Callahan, Research Scientist > Delaware Geological Survey, University of Delaware > URL: http://www.dgs.udel.edu > ************************************************* > > > > > On Mon, Apr 23, 2012 at 3:27 PM, Donald Kerr > wrote: > > Can anyone give me an idea of timescales for the release of PostGIS > 2.0.0 support in Mapserver and then MS4W please? > > Many thanks. > > Regards, > > Donald > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From melanie.poser-hartmann at muenchen.de Tue Apr 24 00:56:48 2012 From: melanie.poser-hartmann at muenchen.de (melanie.poser-hartmann) Date: Tue, 24 Apr 2012 00:56:48 -0700 (PDT) Subject: [mapserver-users] Re: Problem with gif lib when compiling mapserver 6.0.2 In-Reply-To: References: <4F9561BF.4030906@muenchen.de> Message-ID: <1335254208977-4912772.post@n6.nabble.com> Hello Thomas, Thank you. It does not accept /usr/local nor /usr nor / nor /usr/local/include/gif_lib.h could it be, that wants another different file ? I found in http://trac.osgeo.org/mapserver/ticket/3836 that without-gif is maybe possible in mapserver 6.2 Mel. -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Problem-with-gif-lib-when-compiling-mapserver-6-0-2-tp4910327p4912772.html Sent from the Mapserver - User mailing list archive at Nabble.com. From melanie.poser-hartmann at muenchen.de Tue Apr 24 02:03:51 2012 From: melanie.poser-hartmann at muenchen.de (melanie.poser-hartmann) Date: Tue, 24 Apr 2012 02:03:51 -0700 (PDT) Subject: [mapserver-users] Re: Problem with gif lib when compiling mapserver 6.0.2 In-Reply-To: <1335254208977-4912772.post@n6.nabble.com> References: <4F9561BF.4030906@muenchen.de> <1335254208977-4912772.post@n6.nabble.com> Message-ID: <1335258231570-4912892.post@n6.nabble.com> Hello, I found the answer. The mapserver6.0.2 configure tool really does not search for gif_lib.h this is the header file for the gif lib file libgif.a http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=114354 says that the packages libungif lacks the libgif.a file. You only have to symlink the libungif.a to libgif.a then it works Mel. -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Problem-with-gif-lib-when-compiling-mapserver-6-0-2-tp4910327p4912892.html Sent from the Mapserver - User mailing list archive at Nabble.com. From thomas.bonfort at gmail.com Tue Apr 24 02:30:41 2012 From: thomas.bonfort at gmail.com (thomas bonfort) Date: Tue, 24 Apr 2012 11:30:41 +0200 Subject: [mapserver-users] Re: Problem with gif lib when compiling mapserver 6.0.2 In-Reply-To: <1335258231570-4912892.post@n6.nabble.com> References: <4F9561BF.4030906@muenchen.de> <1335254208977-4912772.post@n6.nabble.com> <1335258231570-4912892.post@n6.nabble.com> Message-ID: Thank you for reporting back. What debian version are you running on, I can't find any reference to libungif in any of the recentish releases? -- thomas On Tue, Apr 24, 2012 at 11:03, melanie.poser-hartmann wrote: > Hello, > > I found the answer. > > The mapserver6.0.2 configure tool really does not search for gif_lib.h this > is the header file for the gif lib file libgif.a > > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=114354 > > says that the packages libungif lacks the libgif.a file. > > You only have to symlink the libungif.a to libgif.a then it works > > Mel. > > -- > View this message in context: http://osgeo-org.1560.n6.nabble.com/Problem-with-gif-lib-when-compiling-mapserver-6-0-2-tp4910327p4912892.html > Sent from the Mapserver - User mailing list archive at Nabble.com. > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From Harald.Eberle at vorarlberg.at Tue Apr 24 02:32:57 2012 From: Harald.Eberle at vorarlberg.at (Eberle Harald) Date: Tue, 24 Apr 2012 09:32:57 +0000 Subject: [mapserver-users] WFS - MINSCALEDENOM and MAXSCALEDENOM In-Reply-To: <882AC4A3E1733B4D9FE48E1209D314110E721A3F@VNVBRWEX3.net.vlr.gv.at> References: <882AC4A3E1733B4D9FE48E1209D314110E721A3F@VNVBRWEX3.net.vlr.gv.at> Message-ID: <882AC4A3E1733B4D9FE48E1209D314110E721A70@VNVBRWEX3.net.vlr.gv.at> Hi, I configured a mapfile for a WFS service. The MINSCALEDENOM and MAXSCALEDENOM don't seem to be working properly since data is displayed at any scale ... I did the same thing for a WMS service (another mapfile) and it works fine. Any idea why it doesn't work with WFS ? With kind regrads, Eberle Harald Abteilung Wasserwirtschaft Amt der Vorarlberger Landesregierung Josef-Huter-Stra?e 35 A-6901 Bregenz Tel: +43(0)5574/511-27447 Fax: +43(0)5574/511-927495 E-Mail: harald.eberle at vorarlberg.at http://www.vorarlberg.at Rechtsverbindlichen Schriftverkehr (zB Antr?ge, Rechtsmittel) richten Sie an: E-Mail: land at vorarlberg.at Fax: +43(0)5574/511-920095 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Harald.Eberle at vorarlberg.at Tue Apr 24 02:29:24 2012 From: Harald.Eberle at vorarlberg.at (Eberle Harald) Date: Tue, 24 Apr 2012 09:29:24 +0000 Subject: [mapserver-users] WFS - MINSCALEDENOM and MAXSCALEDENOM Message-ID: <882AC4A3E1733B4D9FE48E1209D314110E721A3F@VNVBRWEX3.net.vlr.gv.at> Hi, I configured a mapfile for a WFS service. The MINSCALEDENOM and MAXSCALEDENOM don't seem to be working properly since data is displayed at any scale ... I did the same thing for a WMS service (another mapfile) and it works fine. Any idea why it doesn't work with WFS ? With kind regrads, Eberle Harald Abteilung Wasserwirtschaft Amt der Vorarlberger Landesregierung Josef-Huter-Stra?e 35 A-6901 Bregenz Tel: +43(0)5574/511-27447 Fax: +43(0)5574/511-927495 E-Mail: harald.eberle at vorarlberg.at http://www.vorarlberg.at Rechtsverbindlichen Schriftverkehr (zB Antr?ge, Rechtsmittel) richten Sie an: E-Mail: land at vorarlberg.at Fax: +43(0)5574/511-920095 -------------- next part -------------- An HTML attachment was scrubbed... URL: From juanma.mr at gmail.com Tue Apr 24 03:00:01 2012 From: juanma.mr at gmail.com (Juanma M. R.) Date: Tue, 24 Apr 2012 12:00:01 +0200 Subject: [mapserver-users] Re: pointObj->project behaviour differences from 4.10 to 5.6 versions Message-ID: Dear Daniel, Thank you for your answer Daniel. I already know that the coordinate I put was out of bounds for this limit. The issue is that I am trying to find the best option to manage this change from one global CRS to a local one, as it is necessary in my application. In version 4.10 it returned values for local CRS and allowed to go back again to global ones. So it worked. However, in version 5.6 it doesn't work at all. That is why I tried to understand the way the function project works in the different versions. After testing and your feedback, obviously I prefer the behaviour of the 5.6 that at least allows you to detect whenever a coordinate is out of the bounds without having to check for each CRS bounds. In version 5.6 project function returns the same coordinates when asking for transforming a coordinate out of bounds for the output CRS. Checking if the function returns the same coordinates helps you detecting this case and it is easier to control it. I don't know if any other user in the list has deal with this problem and used another way to implement it. Best regards, > Message: 1 > Date: Mon, 23 Apr 2012 14:03:20 -0400 > From: Daniel Morissette > Subject: Re: [mapserver-users] pointObj->project behaviour differences > from 4.10 to 5.6 versions > To: mapserver-users at lists.osgeo.org > Message-ID: <4F959968.3040204 at mapgears.com> > Content-Type: text/plain; charset=windows-1252; format=flowed > > EPSG:32630 is UTM Zone 30N ... > > http://spatialreference.org/ref/epsg/32630/ > > A UTM coordinate system is defined for a limited area, a UTM zone has a > width of 6 degrees of longitude, in this case > > EPSG:32630 > WGS 84 / UTM zone 30N > WGS84 Bounds: -6.0000, 0.0000, 0.0000, 84.0000 > > It is very likely that you are getting random values from various PROJ > versions because your -116, -15 test coordinate is outside of the area > of validity of the EPSG:32630 coordinate system. > > Daniel > > > On 12-04-23 9:39 AM, Juanma M. R. wrote: > > Hi, > > > > I have been doing more tests to try to identify exactly the problem and > > I ahve realized that, according to http://twcc.free.fr/, the coordinates > > returned when working with php_mapscript from version 4.10 are not > > correct. I am trying to get where is the problem, so that I can decide > > wether sorting out a The issue is that the function project returns > > different things depending on the server configuration: > > > > Input coordinates in Google Spherical Mercator: > > (-20500513.477395,-3641436. > > 715144) > > > > Server 1: proj 4.1.5 and MapServer 4.10 returns > > (-90270074.105905,-216622133.8792) > > Server 2: proj 4.1.7 and MapServer 5.6 returns > > (-20500513.477395,-3641436.715144) > > The World Coordinate Converter automatically transform the output CRS to > > UTM 60S, so I can't not validate the transformation with it. > > > > The issue is that I would like to understand the expected behaviour from > > this function, so that I can go on checking it and defining the best way > > to support the functionality or detecting a problem in servers > > configuration. > > > > The code is as follows: > > > > function project($x, $y, $srsIn, $srsOut) > > { > > $pointObj=ms_newPointObj(); > > > > $pointObj->setXY($x,$y); > > > > > > $pointObj->project(ms_newProjectionObj("init=".strtolower($srsIn)), > > ms_newProjectionObj("init=".strtolower($srsOut))); > > > > $xout=$pointObj->x; > > $yout=$pointObj->y; > > > > $pointObj->free(); > > > > return $xout.",".$yout; > > } > > ?> > > > > > > 2012/4/16 Lime, Steve D (DNR) > > > > > > The transformation is done in place, I?ve not had problems with it. > > What language? Can you post a code snippet?____ > > > > __ __ > > > > *From:*mapserver-users-bounces at lists.osgeo.org > > > > [mailto:mapserver-users-bounces at lists.osgeo.org > > ] *On Behalf Of > > *Juanma M. R. > > *Sent:* Thursday, April 12, 2012 4:13 AM > > *To:* mapserver-users at lists.osgeo.org > > > > *Subject:* [mapserver-users] pointObj->project behaviour differences > > from 4.10 to 5.6 versions____ > > > > __ __ > > > > Dear list, > > > > I have a webgis application working with different CRS all over the > > world. I have realized that the behaviour from version 4.10 of the > > function pointObj->project differs from the one of version 5.6 from > > Mapserver. For example, I try to convert (-116,-15) in 4326 and in > > mapscript from version 4.10 it returns > > (-26158630.407638,-25040425.679281) when passing to 32630. On the > > other hand, in version 5.6 of mapscript it returns the original > > coordinates without transforming them. > > > > Is this intended or am I doing something wrong? Which is the > > intended behaviour of project function in MapServer 5.6? > > > > Best regards, > > -- > > Juan Manuel Moreno Rivera. > > University of Castilla-La Mancha > > Albacete, Spain____ > > > > > > > > > > -- > > Juan Manuel Moreno Rivera. > > University of Castilla-La Mancha > > Albacete, Spain > > > > > > _______________________________________________ > > mapserver-users mailing list > > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > -- > Daniel Morissette > http://www.mapgears.com/ > Provider of Professional MapServer Support since 2000 > > > -- Juan Manuel Moreno Rivera. University of Castilla-La Mancha Albacete, Spain -------------- next part -------------- An HTML attachment was scrubbed... URL: From melanie.poser-hartmann at muenchen.de Tue Apr 24 03:07:17 2012 From: melanie.poser-hartmann at muenchen.de (melanie.poser-hartmann) Date: Tue, 24 Apr 2012 03:07:17 -0700 (PDT) Subject: [mapserver-users] Re: Problem with gif lib when compiling mapserver 6.0.2 In-Reply-To: References: <4F9561BF.4030906@muenchen.de> <1335254208977-4912772.post@n6.nabble.com> <1335258231570-4912892.post@n6.nabble.com> Message-ID: <1335262037118-4913027.post@n6.nabble.com> No , I'm using Solaris 10 x86 and installed the libungif-4.1.4. from sunfreeware.com After installing you have the gif_lib.h in /usr/local/include and a libungif.a in /usr/local/lib Mel. -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Problem-with-gif-lib-when-compiling-mapserver-6-0-2-tp4910327p4913027.html Sent from the Mapserver - User mailing list archive at Nabble.com. From Steve.Lime at state.mn.us Tue Apr 24 06:07:05 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Tue, 24 Apr 2012 13:07:05 +0000 Subject: [mapserver-users] RE: WFS - MINSCALEDENOM and MAXSCALEDENOM In-Reply-To: <882AC4A3E1733B4D9FE48E1209D314110E721A3F@VNVBRWEX3.net.vlr.gv.at> References: <882AC4A3E1733B4D9FE48E1209D314110E721A3F@VNVBRWEX3.net.vlr.gv.at> Message-ID: Scale can only be computed for getmap type requests. I don't think that's possible for what amounts to a query service. What type of request and output are you using? Steve ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] on behalf of Eberle Harald [Harald.Eberle at vorarlberg.at] Sent: Tuesday, April 24, 2012 4:29 AM To: 'mapserver-users at lists.osgeo.org' Subject: [mapserver-users] WFS - MINSCALEDENOM and MAXSCALEDENOM Hi, I configured a mapfile for a WFS service. The MINSCALEDENOM and MAXSCALEDENOM don?t seem to be working properly since data is displayed at any scale ... I did the same thing for a WMS service (another mapfile) and it works fine. Any idea why it doesn't work with WFS ? With kind regrads, Eberle Harald Abteilung Wasserwirtschaft Amt der Vorarlberger Landesregierung Josef-Huter-Stra?e 35 A-6901 Bregenz Tel: +43(0)5574/511-27447 Fax: +43(0)5574/511-927495 E-Mail: harald.eberle at vorarlberg.at http://www.vorarlberg.at Rechtsverbindlichen Schriftverkehr (zB Antr?ge, Rechtsmittel) richten Sie an: E-Mail: land at vorarlberg.at Fax: +43(0)5574/511-920095 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Tue Apr 24 10:09:54 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Tue, 24 Apr 2012 12:09:54 -0500 Subject: [mapserver-users] tinyows sample links. Message-ID: <4F969812020000A80003587C@heckle> did any of these links get merged into the Mapserver site?: http://tinyows.org/tracdocs/demo/OpenLayers-2.9/examples/tinyows.html >> from this page >> http://mapserver.org/trunk/tinyows/openlayershowtobasic.html and http://tinyows.org/tracdocs/demo/OpenLayers-2.9/examples/tinyows_wfs-t.html .. from this page >> http://mapserver.org/trunk/tinyows/openlayershowtotransactional.html thanks bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Wed Apr 25 07:41:48 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Wed, 25 Apr 2012 09:41:48 -0500 Subject: [mapserver-users] Label a point in a legend arbitrarily. Message-ID: <4F97C6DC020000A800035996@heckle> All, I recall doing this with a symbol in the past, but is there a way (yet) to arbitrarily label a point (symbol) in a legend? bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From john.callahan at udel.edu Wed Apr 25 10:09:18 2012 From: john.callahan at udel.edu (John Callahan) Date: Wed, 25 Apr 2012 13:09:18 -0400 Subject: [mapserver-users] GeoSciML in Mapserver WFS Message-ID: Does anyone have experience in implementing GeoSciML (instead of GML) through Mapserver WFS? I've read that Apache Cocoon can be used for an alternate XML format. However, can Mapserver be configured to use something like OUTPUTFORMAT=GEOSCIML? Thanks for any advice. - John *********************************************** John Callahan, Research Scientist Delaware Geological Survey, University of Delaware URL: http://www.dgs.udel.edu ************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at state.mn.us Wed Apr 25 10:38:35 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Wed, 25 Apr 2012 17:38:35 +0000 Subject: [mapserver-users] Label a point in a legend arbitrarily. In-Reply-To: <4F97C6DC020000A800035996@heckle> References: <4F97C6DC020000A800035996@heckle> Message-ID: You mean via URL? What version of MapServer? From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Wednesday, April 25, 2012 9:42 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Label a point in a legend arbitrarily. All, I recall doing this with a symbol in the past, but is there a way (yet) to arbitrarily label a point (symbol) in a legend? bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From john.callahan at udel.edu Wed Apr 25 10:48:53 2012 From: john.callahan at udel.edu (John Callahan) Date: Wed, 25 Apr 2012 13:48:53 -0400 Subject: [mapserver-users] GeoSciML in Mapserver WFS In-Reply-To: <888F01881A52054AAE5177DB839FAAE302E301@S-BSC-MBX1.nrn.nrcan.gc.ca> References: <888F01881A52054AAE5177DB839FAAE302E301@S-BSC-MBX1.nrn.nrcan.gc.ca> Message-ID: Thank you Eric for the response and references. Yes, working with OneGeology is one of the reasons why GeoSCiML through Mapserver would be useful to us. Their cookbooks do provide some good information. At this point, using Apache Cocoon or moving to Geoserver/Deegree for this work seem to be the best options. - John *********************************************** John Callahan, Research Scientist Delaware Geological Survey, University of Delaware URL: http://www.dgs.udel.edu ************************************************* On Wed, Apr 25, 2012 at 1:34 PM, Boisvert, Eric < Eric.Boisvert at rncan-nrcan.gc.ca> wrote: > ** > Deegree and GeoServer can, Mapserver is limited to GML Simple Feature > (AFAIK), but XSLT over the output can do the trick in some situations. > > See Alistair Ritchie'S excellent documentation at > https://www.seegrid.csiro.au/wiki/CGIModel/GeoSciMLReferenceDataset > and > https://www.seegrid.csiro.au/wiki/CGIModel/DeegreeGeoSciMLImplementation > > Snowflake is also an $ alternative. > > One Geology has a couple of cookbook you might be interested in. > > http://www.onegeology.org/misc/downloads.html > > > ------------------------------ > *De :* mapserver-users-bounces at lists.osgeo.org [mailto: > mapserver-users-bounces at lists.osgeo.org] *De la part de* John Callahan > *Envoy? :* 25 avril 2012 13:09 > *? :* mapserver-users at lists.osgeo.org > *Objet :* [mapserver-users] GeoSciML in Mapserver WFS > > Does anyone have experience in implementing GeoSciML (instead of GML) > through Mapserver WFS? I've read that Apache Cocoon can be used for an > alternate XML format. However, can Mapserver be configured to use > something like OUTPUTFORMAT=GEOSCIML? > > Thanks for any advice. > > - John > > *********************************************** > John Callahan, Research Scientist > Delaware Geological Survey, University of Delaware > URL: http://www.dgs.udel.edu > ************************************************* > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Wed Apr 25 11:26:35 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Wed, 25 Apr 2012 13:26:35 -0500 Subject: [mapserver-users] Label a point in a legend arbitrarily. In-Reply-To: References: <4F97C6DC020000A800035996@heckle> Message-ID: <4F97FB8B020000A8000359DA@heckle> Steve, In the Mapfile would be fine. But via URL would be a plus as well. I want to put a number, let's say "99" in each of these GPS symbols. http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/plots_last_big_public.map?mapext=541700.2052631578%20136179.92631578946%20604177.1947368421%20174720.92631578946&mapsize=924%20570&mode=legend Oh, man, version . . . version . . . Umm, an old one . . . bobb >>> "Lime, Steve D (DNR)" wrote: You mean via URL? What version of MapServer? From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Wednesday, April 25, 2012 9:42 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Label a point in a legend arbitrarily. All, I recall doing this with a symbol in the past, but is there a way (yet) to arbitrarily label a point (symbol) in a legend? bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at state.mn.us Wed Apr 25 14:50:13 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Wed, 25 Apr 2012 21:50:13 +0000 Subject: [mapserver-users] Label a point in a legend arbitrarily. In-Reply-To: <4F97FB8B020000A8000359DA@heckle> References: <4F97C6DC020000A800035996@heckle> <4F97FB8B020000A8000359DA@heckle> Message-ID: Oh, I get what you're after. Offhand I'd say no. You'd need a way to treat the '99' as a symbol and not a label, that way the legend code will render it. Legends know nothing of labels. I suppose you could try creating a truetype symbol with a regular font (e.g. arial) and then set CHARACTER '99' in the symbol definition. Then you'd use two styles, one for the GPS symbol and one for the text symbol. That might work but you can't muck with a symbol's character value via URL. Steve From: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] Sent: Wednesday, April 25, 2012 1:27 PM To: mapserver-users at lists.osgeo.org; Lime, Steve D (DNR) Subject: RE: [mapserver-users] Label a point in a legend arbitrarily. Steve, In the Mapfile would be fine. But via URL would be a plus as well. I want to put a number, let's say "99" in each of these GPS symbols. http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/plots_last_big_public.map?mapext=541700.2052631578%20136179.92631578946%20604177.1947368421%20174720.92631578946&mapsize=924%20570&mode=legend Oh, man, version . . . version . . . Umm, an old one . . . bobb >>> "Lime, Steve D (DNR)" > wrote: You mean via URL? What version of MapServer? From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Wednesday, April 25, 2012 9:42 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Label a point in a legend arbitrarily. All, I recall doing this with a symbol in the past, but is there a way (yet) to arbitrarily label a point (symbol) in a legend? bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Thu Apr 26 07:43:53 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Thu, 26 Apr 2012 09:43:53 -0500 Subject: [mapserver-users] Label a point in a legend arbitrarily. In-Reply-To: References: <4F97C6DC020000A800035996@heckle> <4F97FB8B020000A8000359DA@heckle> Message-ID: <4F9918D9020000A800035A6F@heckle> Ok, then, only via Symbols. Check. thanks bobb >>> "Lime, Steve D (DNR)" wrote: Oh, I get what you?re after. Offhand I?d say no. You?d need a way to treat the ?99? as a symbol and not a label, that way the legend code will render it. Legends know nothing of labels. I suppose you could try creating a truetype symbol with a regular font (e.g. arial) and then set CHARACTER ?99? in the symbol definition. Then you?d use two styles, one for the GPS symbol and one for the text symbol. That might work but you can?t muck with a symbol?s character value via URL. Steve From: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] Sent: Wednesday, April 25, 2012 1:27 PM To: mapserver-users at lists.osgeo.org; Lime, Steve D (DNR) Subject: RE: [mapserver-users] Label a point in a legend arbitrarily. Steve, In the Mapfile would be fine. But via URL would be a plus as well. I want to put a number, let's say "99" in each of these GPS symbols. http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/plots_last_big_public.map?mapext=541700.2052631578%20136179.92631578946%20604177.1947368421%20174720.92631578946&mapsize=924%20570&mode=legend Oh, man, version . . . version . . . Umm, an old one . . . bobb >>> "Lime, Steve D (DNR)" wrote: You mean via URL? What version of MapServer? From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Wednesday, April 25, 2012 9:42 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Label a point in a legend arbitrarily. All, I recall doing this with a symbol in the past, but is there a way (yet) to arbitrarily label a point (symbol) in a legend? bobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at state.mn.us Thu Apr 26 09:33:07 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Thu, 26 Apr 2012 16:33:07 +0000 Subject: [mapserver-users] RE: mapserver 5.6 CGI output GeoJSON format 2 In-Reply-To: References: Message-ID: Your pattern allows for upper case letters and you're passing lower case. Hence the error. Steve From: Li Quansheng [mailto:quansheng.cs at gmail.com] Sent: Saturday, April 21, 2012 10:38 AM To: mapserver-users at lists.osgeo.org; Lime, Steve D (DNR) Subject: mapserver 5.6 CGI output GeoJSON format 2 hi guys,Steve A few day ago I post an item " mapserver 5.6 CGI output GeoJSON format " here in which I asked a question about mapserver CGI output GeoJSON,finally with Steve's help I got it! URL1:http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qformat=geojson. But now I want to add where-clause to prefilter,or I want set filter with CGI. The 'tielu' layer stored in postgis including these fields: gid,type,name,comment,the_geom, then I execute URL2:http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=nquery&qlayer=tielu&qitem=name&qstring=namexx&qformat=geojson but the output is as same as the URL1's output, in fact the qstring, qitem don't take affect. I searched and visited http://www.osgeo.org/pipermail/mapserver-users/2003-April/042003.html and http://lists.osgeo.org/pipermail/mapserver-users/2009-August/062581.html, which are all Steve's ansewer posts. so I modified tielu layer in the mapfile as Steve's suggestion, ... METADATA 'ows_title' 'tielu' "wfs_title" "tielu" .... "qstring_validation_pattern" '^[A-Z]{2,8}$' END ... then I execute http://192.168.207.100/cgi-bin/mapserv?map=/opt/fgs/www/htdocs/xj1/xj1.map&layer=tielu&mode=itemnquery&qlayer=tielu&qitem=name&qstring=namexx&qformat=geojson, and returns the error, mapserv(): Web application error. Parameter 'qstring' value fails to validate. msValidateParameter(): Regular expression error. Parameter pattern validation failed. msEvalRegex(): Regular expression error. String failed expression test. I have to search and search, but couldn't work out. any suggestion, thans very much. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Thu Apr 26 09:37:25 2012 From: bfraser at geoanalytic.com (Brent Fraser) Date: Thu, 26 Apr 2012 10:37:25 -0600 Subject: [mapserver-users] GeoSciML in Mapserver WFS In-Reply-To: References: Message-ID: <4F9979C5.5000303@geoanalytic.com> Maybe. Have a look at http://mapserver.org/output/template_output.html Best Regards, Brent Fraser On 4/25/2012 11:09 AM, John Callahan wrote: > Does anyone have experience in implementing GeoSciML (instead of GML) > through Mapserver WFS? I've read that Apache Cocoon can be used for > an alternate XML format. However, can Mapserver be configured to use > something like OUTPUTFORMAT=GEOSCIML? > > Thanks for any advice. > > - John > > *********************************************** > John Callahan, Research Scientist > Delaware Geological Survey, University of Delaware > URL: http://www.dgs.udel.edu > ************************************************* > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From fernando at globalgeo.com.br Thu Apr 26 11:30:01 2012 From: fernando at globalgeo.com.br (Fernando Norte) Date: Thu, 26 Apr 2012 15:30:01 -0300 Subject: [mapserver-users] Dynamic legends Message-ID: Hi, I'd had a mapServer with WMS and visible by OpenLayers, in that there is a layer to "use and occupation of the land", with several (19) types of use, with colors detailed with class/styles. Recently I'd make a run-time configuration filter to choose the exibition of this type of this use. The mapServer can be viewed here: http://globalgeosig.com.br/tizo Now I need to filter the legend to show only the selected types, and try to filter the legend to the only types showed at zoom level extension. I know that this kind of legend I had been used it's not apropriate, because it's an image only, and I know that I can make it with HTML template. But i can't find any way to filter those data. Someone have any ideia about how can I do this. I think this perhaps will use mapscript (php or python) to build. There is right, or there is a possible feature withouth use the mapscript? I know that like the run-time filter I can 'redraw' the map through javascript, I hope to find something similar to legends. Thanks, *Fernando Norte* Desenvolvedor SIGWeb tel.(31) 2533.9900 cel.(31) 9119.8814 skype: fernandoglobalgeo Endere?o: Alameda do Ing?, 88, 6? andar, Vale do Sereno Nova Lima/MG - CEP: 34.000-000 www.globalgeo.com.br "O presente documento pode conter material confidencial ou seu sigilo ? protegido por lei. Quaisquer informa??es nele contida s?o destinadas exclusivamente ao(s) seu(s) destinat?rio(s) n?o devendo em nenhuma hip?tese ser repassado a terceiros". -------------- next part -------------- An HTML attachment was scrubbed... URL: From Paul.Maddock at ijus.net Thu Apr 26 13:51:40 2012 From: Paul.Maddock at ijus.net (Paul Maddock) Date: Thu, 26 Apr 2012 16:51:40 -0400 Subject: [mapserver-users] Postgis/mapserver error Message-ID: <4FDD345A70B42F479A0B3329E101EC65A8D658258F@mx-02.ijuscol.com> Dear all, I'm currently trying to have mapserver v6.0.1 grab data from my postgis database v 2.0.0 . When I request the layer through mapserver using cgi commands I get the following error message: msDrawMap(): Image handling error. Failed to draw layer named 'aep_polygon_polyline'. msPostGISLayerWhichShapes(): Query error. Error (ERROR: function geomfromtext(unknown, integer) does not exist LINE 1: ...gid" from aep_polygon_polyline where geom_3754 && GeomFromTe... ^ HINT: No function matches the given name and argument types. You might need to add explicit type casts. ) executing query: select encode(ST_AsBinary(ST_Force_2D("geom_3754"),'NDR'),'hex') as geom,"gid" from aep_polygon_polyline where geom_3754 && GeomFromText('POLYGON((980934.251404232 125495.986,980934.251404232 1038792.604,2809561.55559577 1038792.604,2809561.55559577 125495.986,980934.251404232 125495.986))',3754) my mapfile looks like this: LAYER NAME "aep_polygon_polyline" STATUS ON TYPE line CONNECTIONTYPE postgis CONNECTION "host=localhost dbname=aep_columbus user=****** password=******** port=5432" DATA "geom_3754 from aep_polygon_polyline using unique gid using srid=3754" PROJECTION "init=epsg:3754" END CLASSITEM 'gid' CLASS STYLE COLOR 200 200 200 OUTLINECOLOR 200 200 200 SIZE 2 END END END I used the following command to create my shapefile: shp2pgsql -s 3754 -g geom_3754 /path/to/my/shpfile | psql -h localhost -U postgres -p 5432 -d aep_columbus 3754 is Ohio State Plane South. Does this mean that I need to use the -G geography option to make my data properly render? Thank you so much, Paul Paul A. Maddock Mapping Technician IJUS LLC 560 Officenter Place Gahanna, OH 43230 Cell: (513) 404-6476 [cid:image001.gif at 01CD23C8.5F79EDB0] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.gif Type: image/gif Size: 3201 bytes Desc: image001.gif URL: From donald.kerr at dkerr.co.uk Thu Apr 26 14:23:25 2012 From: donald.kerr at dkerr.co.uk (Donald Kerr) Date: Thu, 26 Apr 2012 22:23:25 +0100 Subject: [mapserver-users] Postgis/mapserver error In-Reply-To: <4FDD345A70B42F479A0B3329E101EC65A8D658258F@mx-02.ijuscol.com> Message-ID: <7FD5B50198A14D58A127B630D7AA244C@DELLM4500> Paul, I had the same issue. The functions have been renamed in PostGIS 2. You need to run legacy_minimal.sql in PostGreSQL. That file can be found here: \PostgreSQL\9.1\share\contrib\postgis-2.0. Regards, Donald -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Paul Maddock Sent: 26 April 2012 21:52 To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Postgis/mapserver error Dear all, I'm currently trying to have mapserver v6.0.1 grab data from my postgis database v 2.0.0 . When I request the layer through mapserver using cgi commands I get the following error message: msDrawMap(): Image handling error. Failed to draw layer named 'aep_polygon_polyline'. msPostGISLayerWhichShapes(): Query error. Error (ERROR: function geomfromtext(unknown, integer) does not exist LINE 1: ...gid" from aep_polygon_polyline where geom_3754 && GeomFromTe... ^ HINT: No function matches the given name and argument types. You might need to add explicit type casts. ) executing query: select encode(ST_AsBinary(ST_Force_2D("geom_3754"),'NDR'),'hex') as geom,"gid" from aep_polygon_polyline where geom_3754 && GeomFromText('POLYGON((980934.251404232 125495.986,980934.251404232 1038792.604,2809561.55559577 1038792.604,2809561.55559577 125495.986,980934.251404232 125495.986))',3754) my mapfile looks like this: LAYER NAME "aep_polygon_polyline" STATUS ON TYPE line CONNECTIONTYPE postgis CONNECTION "host=localhost dbname=aep_columbus user=****** password=******** port=5432" DATA "geom_3754 from aep_polygon_polyline using unique gid using srid=3754" PROJECTION "init=epsg:3754" END CLASSITEM 'gid' CLASS STYLE COLOR 200 200 200 OUTLINECOLOR 200 200 200 SIZE 2 END END END I used the following command to create my shapefile: shp2pgsql -s 3754 -g geom_3754 /path/to/my/shpfile | psql -h localhost -U postgres -p 5432 -d aep_columbus 3754 is Ohio State Plane South. Does this mean that I need to use the -G geography option to make my data properly render? Thank you so much, Paul Paul A. Maddock Mapping Technician IJUS LLC 560 Officenter Place Gahanna, OH 43230 Cell: (513) 404-6476 Description: Description: Home -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.gif Type: image/gif Size: 3201 bytes Desc: not available URL: From punk.kish at gmail.com Thu Apr 26 16:35:29 2012 From: punk.kish at gmail.com (Puneet Kishor) Date: Thu, 26 Apr 2012 18:35:29 -0500 Subject: [mapserver-users] elevation profile Message-ID: Any suggestions on how something like this could be implemented using MapServer? http://viewer.nationalmap.gov/example/elevation_profile.html My front-end is OpenLayers, and the backend data are from SRTM. I'd like to click on the map and create a line, and get back the elevation numbers for that line. I only want the elevation numbers as I can optionally construct the profile via a variety of ways. I am assuming I could send a line WKT, but how would I query for the values using MapServer? Fwiw, http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html seems to use a canvas implementation that doesn't seem to be available in my standard-issue OL 2.11. Calling `this.layer.getPixelDataForViewPortPx` croaks with "not a function" message. In any case, I don't really want the RGB values under the mouse. I want the actual height values. Thanks in advance for any suggestions, -- Puneet Kishor From woodbri at swoodbridge.com Thu Apr 26 17:20:44 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Thu, 26 Apr 2012 20:20:44 -0400 Subject: [mapserver-users] elevation profile In-Reply-To: References: Message-ID: <4F99E65C.7060504@swoodbridge.com> On 4/26/2012 7:35 PM, Puneet Kishor wrote: > Any suggestions on how something like this could be implemented using MapServer? > > http://viewer.nationalmap.gov/example/elevation_profile.html > > > My front-end is OpenLayers, and the backend data are from SRTM. I'd like to click on the map and create a line, and get back the elevation numbers for that line. I only want the elevation numbers as I can optionally construct the profile via a variety of ways. > > I am assuming I could send a line WKT, but how would I query for the values using MapServer? > > Fwiw, http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html seems to use a canvas implementation that doesn't seem to be available in my standard-issue OL 2.11. Calling `this.layer.getPixelDataForViewPortPx` croaks with "not a function" message. In any case, I don't really want the RGB values under the mouse. I want the actual height values. > > Thanks in advance for any suggestions, Hi Puneet, I have done this in the past and there are a bunch of moving parts. Here is what I did. 1. got a copy of NED2 data for the US. 2. create a gdal .vrt file to pull all the files into a single virtual file 3. wrote a simple C fcgi program to take an x,y and get the elevation from the the NED2 data. http://imaptools.com:8080/cgi-bin/getElevation.fcgi?lat=32.662864999999996&lon=-86.880096999999992 4. I used pgRouting to compute a route and then took the route geometry and added sample point along the edges where needed, and hit the fcgi service to convert the points to elevations and then plotted the elevations against the their length along the line that the x,y represented. I also think I may have wrote an app where you could pass the route polyline to it an it would generate an image of the elevation plot. 5. Then wired it into the web page as an ajax call of as a image url that gets updated. -Steve W From woodbri at swoodbridge.com Thu Apr 26 17:23:12 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Thu, 26 Apr 2012 20:23:12 -0400 Subject: [mapserver-users] elevation profile In-Reply-To: <4F99E65C.7060504@swoodbridge.com> References: <4F99E65C.7060504@swoodbridge.com> Message-ID: <4F99E6F0.9030500@swoodbridge.com> Oh, one more point I wanted to mention is that the new PostGIS raster code might let you load the NED2 data directly into the database and get the contour information via a SQL query. But I have not try to do that yet. -Steve W On 4/26/2012 8:20 PM, Stephen Woodbridge wrote: > On 4/26/2012 7:35 PM, Puneet Kishor wrote: >> Any suggestions on how something like this could be implemented using >> MapServer? >> >> http://viewer.nationalmap.gov/example/elevation_profile.html >> >> >> My front-end is OpenLayers, and the backend data are from SRTM. I'd >> like to click on the map and create a line, and get back the elevation >> numbers for that line. I only want the elevation numbers as I can >> optionally construct the profile via a variety of ways. >> >> I am assuming I could send a line WKT, but how would I query for the >> values using MapServer? >> >> Fwiw, >> http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html >> seems to use a canvas implementation that doesn't seem to be available >> in my standard-issue OL 2.11. Calling >> `this.layer.getPixelDataForViewPortPx` croaks with "not a function" >> message. In any case, I don't really want the RGB values under the >> mouse. I want the actual height values. >> >> Thanks in advance for any suggestions, > > Hi Puneet, > > I have done this in the past and there are a bunch of moving parts. Here > is what I did. > > 1. got a copy of NED2 data for the US. > 2. create a gdal .vrt file to pull all the files into a single virtual file > 3. wrote a simple C fcgi program to take an x,y and get the elevation > from the the NED2 data. > > http://imaptools.com:8080/cgi-bin/getElevation.fcgi?lat=32.662864999999996&lon=-86.880096999999992 > > > 4. I used pgRouting to compute a route and then took the route geometry > and added sample point along the edges where needed, and hit the fcgi > service to convert the points to elevations and then plotted the > elevations against the their length along the line that the x,y > represented. > > I also think I may have wrote an app where you could pass the route > polyline to it an it would generate an image of the elevation plot. > > 5. Then wired it into the web page as an ajax call of as a image url > that gets updated. > > -Steve W > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From punk.kish at gmail.com Thu Apr 26 19:49:13 2012 From: punk.kish at gmail.com (Puneet Kishor) Date: Thu, 26 Apr 2012 21:49:13 -0500 Subject: [mapserver-users] elevation profile In-Reply-To: <4F99E65C.7060504@swoodbridge.com> References: <4F99E65C.7060504@swoodbridge.com> Message-ID: <950B4E25-E855-4786-86E6-347A8E1C9923@gmail.com> On Apr 26, 2012, at 7:20 PM, Stephen Woodbridge wrote: > On 4/26/2012 7:35 PM, Puneet Kishor wrote: >> Any suggestions on how something like this could be implemented using MapServer? >> >> http://viewer.nationalmap.gov/example/elevation_profile.html >> >> >> My front-end is OpenLayers, and the backend data are from SRTM. I'd like to click on the map and create a line, and get back the elevation numbers for that line. I only want the elevation numbers as I can optionally construct the profile via a variety of ways. >> >> I am assuming I could send a line WKT, but how would I query for the values using MapServer? >> >> Fwiw, http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html seems to use a canvas implementation that doesn't seem to be available in my standard-issue OL 2.11. Calling `this.layer.getPixelDataForViewPortPx` croaks with "not a function" message. In any case, I don't really want the RGB values under the mouse. I want the actual height values. >> >> Thanks in advance for any suggestions, > > Hi Puneet, > > I have done this in the past and there are a bunch of moving parts. Here is what I did. > > 1. got a copy of NED2 data for the US. > 2. create a gdal .vrt file to pull all the files into a single virtual file > 3. wrote a simple C fcgi program to take an x,y and get the elevation from the the NED2 data. > > http://imaptools.com:8080/cgi-bin/getElevation.fcgi?lat=32.662864999999996&lon=-86.880096999999992 > > 4. I used pgRouting to compute a route and then took the route geometry and added sample point along the edges where needed, and hit the fcgi service to convert the points to elevations and then plotted the elevations against the their length along the line that the x,y represented. > > I also think I may have wrote an app where you could pass the route polyline to it an it would generate an image of the elevation plot. > > 5. Then wired it into the web page as an ajax call of as a image url that gets updated. > Thanks for the details, Steve. All this is way more complicated that I was envisioning. And, PostGIS 2 is out of the question, for now, at least. Could you send me that gdal .vrt file? I'd like to look at it. Perhaps that will give me some other ideas on how to approach this. Many thanks, -- Puneet Kishor From woodbri at swoodbridge.com Thu Apr 26 20:39:56 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Thu, 26 Apr 2012 23:39:56 -0400 Subject: [mapserver-users] elevation profile In-Reply-To: <950B4E25-E855-4786-86E6-347A8E1C9923@gmail.com> References: <4F99E65C.7060504@swoodbridge.com> <950B4E25-E855-4786-86E6-347A8E1C9923@gmail.com> Message-ID: <4F9A150C.3060301@swoodbridge.com> On 4/26/2012 10:49 PM, Puneet Kishor wrote: > > On Apr 26, 2012, at 7:20 PM, Stephen Woodbridge wrote: > >> On 4/26/2012 7:35 PM, Puneet Kishor wrote: >>> Any suggestions on how something like this could be implemented >>> using MapServer? >>> >>> http://viewer.nationalmap.gov/example/elevation_profile.html >>> >>> >>> My front-end is OpenLayers, and the backend data are from SRTM. >>> I'd like to click on the map and create a line, and get back the >>> elevation numbers for that line. I only want the elevation >>> numbers as I can optionally construct the profile via a variety >>> of ways. >>> >>> I am assuming I could send a line WKT, but how would I query for >>> the values using MapServer? >>> >>> Fwiw, >>> http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html >>> seems to use a canvas implementation that doesn't seem to be >>> available in my standard-issue OL 2.11. Calling >>> `this.layer.getPixelDataForViewPortPx` croaks with "not a >>> function" message. In any case, I don't really want the RGB >>> values under the mouse. I want the actual height values. >>> >>> Thanks in advance for any suggestions, >> >> Hi Puneet, >> >> I have done this in the past and there are a bunch of moving parts. >> Here is what I did. >> >> 1. got a copy of NED2 data for the US. 2. create a gdal .vrt file >> to pull all the files into a single virtual file 3. wrote a simple >> C fcgi program to take an x,y and get the elevation from the the >> NED2 data. >> >> http://imaptools.com:8080/cgi-bin/getElevation.fcgi?lat=32.662864999999996&lon=-86.880096999999992 >> >> >> 4. I used pgRouting to compute a route and then took the route geometry and added sample point along the edges where needed, and hit the fcgi service to convert the points to elevations and then plotted the elevations against the their length along the line that the x,y represented. >> >> I also think I may have wrote an app where you could pass the route >> polyline to it an it would generate an image of the elevation >> plot. >> >> 5. Then wired it into the web page as an ajax call of as a image >> url that gets updated. >> > > > > Thanks for the details, Steve. All this is way more complicated that > I was envisioning. And, PostGIS 2 is out of the question, for now, at > least. > > Could you send me that gdal .vrt file? I'd like to look at it. > Perhaps that will give me some other ideas on how to approach this. Puneet, GDAL has a utility gdalbuildvrt the creates the .vrt file I think I ran it something like: gdalbuildvrt ned2.vrt /u/data/ned2/*.tif run gdalbuildvrt with no arguments to get some help. If you want you could use mapserver and set up a point query against the ned2 data to get the elevation, then write a php wrapper to take the polyline and sample it and call mapserver to get the elevations along the polyline and you the php gd code to plot it out. -Steve From peter.hopfgartner at r3-gis.com Fri Apr 27 06:04:09 2012 From: peter.hopfgartner at r3-gis.com (Peter Hopfgartner) Date: Fri, 27 Apr 2012 15:04:09 +0200 Subject: [mapserver-users] Fail to build Mapscript Python with current source Message-ID: <4F9A9949.3070506@r3-gis.com> I'm on a CentOS 6.2, x86_64 bit system: /configure --with-gd --with-zlib --with-tiff --with-agg --with-experimental-png --with-freetype=/usr/bin/freetype-config --with-gdal=/usr/bin/gdal-config --with-ogr=/usr/bin/gdal-config --with-geos=/usr/bin/geos-config --with-cairo=yes --with-proj --with-wfs --with-wcs --with-sos --with-wmsclient --with-wfsclient --with-xpm --with-postgis=/usr/bin/pg_config --with-mygis=/usr/bin/mysql_config --with-curl-config=/usr/bin/curl-config --with-xml2-config=/usr/bin/xml2-config --with-php=/usr/bin/php-config --with-fribidi-config=/usr/lib64/pkgconfig/fribidi.pc --with-fastcgi=/usr --without-pdf --without-eppl --with-threads --enable-debug --disable-runpath cd mapscript/python swig -python -shadow -modern -o mapscript_wrap.c ../mapscript.i cd ../.. make cd mapscript/python python setup.py build The build fails with: gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -DUSE_FASTCGI=1 -DUSE_CAIRO=1 -DUSE_FRIBIDI=1 -DUSE_FRIBIDI2=1 -DUSE_WMS_LYR=1 -DUSE_WFS_LYR=1 -DUSE_SOS_SVR=1 -DUSE_LIBXML2=1 -DUSE_CURL=1 -DUSE_CURLOPT_PROXYAUTH=1 -DUSE_WCS_SVR=1 -DUSE_WFS_SVR=1 -DUSE_WMS_SVR=1 -DUSE_POSTGIS=1 -DPOSTGIS_HAS_SERVER_VERSION=1 -DUSE_GDAL=1 -DUSE_OGR=1 -DUSE_GEOS=1 -DUSE_THREAD=1 -DUSE_PROJ=1 -DUSE_GD=1 -DUSE_GD_GIF=1 -DUSE_GD_PNG=1 -DUSE_GD_JPEG=1 -DUSE_GD_WBMP=1 -DUSE_GD_FT=1 -DGD_HAS_FTEX_XSHOW=1 -DGD_HAS_GDIMAGEGIFPTR=1 -DGD_HAS_GETBITMAPFONTS=1 -DGD_HAS_GET_TRUE_COLOR_PIXEL=1 -DUSE_ICONV=1 -DUSE_JPEG=1 -DUSE_GIF=1 -DUSE_PNG=1 -DUSE_ZLIB=1 -DUSE_FREETYPE=1 -DHAVE_VSNPRINTF=1 -DNEED_STRLCPY=1 -DNEED_STRLCAT=1 -DNEED_STRRSTR=1 -DDISABLE_CVSID=1 -I../.. -I/usr/include/freetype2 -Irenderers/agg/include -I/usr/include/gdal -I/usr/include -I/usr/include/fastcgi -I/usr/include/libxml2 -I/usr/include/fribidi -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libpng12 -I/usr/include/python2.6 -I/home/rpmbuild/tmp/mapserver-6.1.20120426 -c pygdioctx/pygdioctx.c -o build/temp.linux-x86_64-2.6/pygdioctx/pygdioctx.o pygdioctx/pygdioctx.c: In function ?PyFileIfaceObj_IOCtx_GetBuf?: pygdioctx/pygdioctx.c:84: warning: passing argument 3 of ?PyString_AsStringAndSize? from incompatible pointer type /usr/include/python2.6/stringobject.h:172: note: expected ?Py_ssize_t *? but argument is of type ?int *? gcc -pthread -shared build/temp.linux-x86_64-2.6/mapscript_wrap.o build/temp.linux-x86_64-2.6/pygdioctx/pygdioctx.o -L../../ -L/usr/lib64 -L/usr/lib64 -L/usr/lib -L/usr/lib64 -L/home/rpmbuild/tmp/mapserver-6.1.20120426 -lpython2.6 -lmapserver -lfreetype -lgd -ljpeg -lpng -lz -lXpm -lX11 -lproj -lgif -lgdal -lpq -lcurl -lgeos_c -lpthread -lc -lfcgi -lxml2 -lm -lfribidi -lstdc++ -lfontconfig -lcairo -lpng12 -lmapserver -o build/lib.linux-x86_64-2.6/_mapscript.so /usr/bin/ld: cannot find -lmapserver collect2: ld returned 1 exit status error: command 'gcc' failed with exit status 1 Anyway, there is a file libmapserver.la in the source directory. What is it, that I'm mising? Thanks, Peter -- Peter Hopfgartner web : http://www.r3-gis.com From umberto.nicoletti at gmail.com Fri Apr 27 06:22:57 2012 From: umberto.nicoletti at gmail.com (Umberto Nicoletti) Date: Fri, 27 Apr 2012 15:22:57 +0200 Subject: [mapserver-users] Fail to build Mapscript Python with current source In-Reply-To: <4F9A9949.3070506@r3-gis.com> References: <4F9A9949.3070506@r3-gis.com> Message-ID: I just built it on Ubuntu 10.04 x86, perhaps you should try this build process: ./configure [your options] --enable-python-mapscript make sudo make install make/make install will also build and install python mapscript, no need to cd, swig, etc. Umberto On Fri, Apr 27, 2012 at 3:04 PM, Peter Hopfgartner < peter.hopfgartner at r3-gis.com> wrote: > I'm on a CentOS 6.2, x86_64 bit system: > > /configure --with-gd --with-zlib --with-tiff --with-agg > --with-experimental-png --with-freetype=/usr/bin/**freetype-config > --with-gdal=/usr/bin/gdal-**config --with-ogr=/usr/bin/gdal-**config > --with-geos=/usr/bin/geos-**config --with-cairo=yes --with-proj > --with-wfs --with-wcs --with-sos --with-wmsclient --with-wfsclient > --with-xpm --with-postgis=/usr/bin/pg_**config > --with-mygis=/usr/bin/mysql_**config --with-curl-config=/usr/bin/**curl-config > --with-xml2-config=/usr/bin/**xml2-config --with-php=/usr/bin/php-config > --with-fribidi-config=/usr/**lib64/pkgconfig/fribidi.pc > --with-fastcgi=/usr --without-pdf --without-eppl --with-threads > --enable-debug --disable-runpath > > cd mapscript/python > swig -python -shadow -modern -o mapscript_wrap.c ../mapscript.i > cd ../.. > make > cd mapscript/python > python setup.py build > > The build fails with: > > gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall > -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector > --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv > -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions > -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic > -D_GNU_SOURCE -fPIC -fwrapv -fPIC -DUSE_FASTCGI=1 -DUSE_CAIRO=1 > -DUSE_FRIBIDI=1 -DUSE_FRIBIDI2=1 -DUSE_WMS_LYR=1 -DUSE_WFS_LYR=1 > -DUSE_SOS_SVR=1 -DUSE_LIBXML2=1 -DUSE_CURL=1 -DUSE_CURLOPT_PROXYAUTH=1 > -DUSE_WCS_SVR=1 -DUSE_WFS_SVR=1 -DUSE_WMS_SVR=1 -DUSE_POSTGIS=1 > -DPOSTGIS_HAS_SERVER_VERSION=1 -DUSE_GDAL=1 -DUSE_OGR=1 -DUSE_GEOS=1 > -DUSE_THREAD=1 -DUSE_PROJ=1 -DUSE_GD=1 -DUSE_GD_GIF=1 -DUSE_GD_PNG=1 > -DUSE_GD_JPEG=1 -DUSE_GD_WBMP=1 -DUSE_GD_FT=1 -DGD_HAS_FTEX_XSHOW=1 > -DGD_HAS_GDIMAGEGIFPTR=1 -DGD_HAS_GETBITMAPFONTS=1 > -DGD_HAS_GET_TRUE_COLOR_PIXEL=**1 -DUSE_ICONV=1 -DUSE_JPEG=1 -DUSE_GIF=1 > -DUSE_PNG=1 -DUSE_ZLIB=1 -DUSE_FREETYPE=1 -DHAVE_VSNPRINTF=1 > -DNEED_STRLCPY=1 -DNEED_STRLCAT=1 -DNEED_STRRSTR=1 -DDISABLE_CVSID=1 > -I../.. -I/usr/include/freetype2 -Irenderers/agg/include > -I/usr/include/gdal -I/usr/include -I/usr/include/fastcgi > -I/usr/include/libxml2 -I/usr/include/fribidi -I/usr/include/cairo > -I/usr/include/pixman-1 -I/usr/include/libpng12 -I/usr/include/python2.6 > -I/home/rpmbuild/tmp/**mapserver-6.1.20120426 -c pygdioctx/pygdioctx.c -o > build/temp.linux-x86_64-2.6/**pygdioctx/pygdioctx.o > pygdioctx/pygdioctx.c: In function ?PyFileIfaceObj_IOCtx_GetBuf?: > pygdioctx/pygdioctx.c:84: warning: passing argument 3 of > ?PyString_AsStringAndSize? from incompatible pointer type > /usr/include/python2.6/**stringobject.h:172: note: expected ?Py_ssize_t > *? but argument is of type ?int *? > gcc -pthread -shared build/temp.linux-x86_64-2.6/**mapscript_wrap.o > build/temp.linux-x86_64-2.6/**pygdioctx/pygdioctx.o -L../../ -L/usr/lib64 > -L/usr/lib64 -L/usr/lib -L/usr/lib64 -L/home/rpmbuild/tmp/**mapserver-6.1.20120426 > -lpython2.6 -lmapserver -lfreetype -lgd -ljpeg -lpng -lz -lXpm -lX11 -lproj > -lgif -lgdal -lpq -lcurl -lgeos_c -lpthread -lc -lfcgi -lxml2 -lm -lfribidi > -lstdc++ -lfontconfig -lcairo -lpng12 -lmapserver -o > build/lib.linux-x86_64-2.6/_**mapscript.so > /usr/bin/ld: cannot find -lmapserver > collect2: ld returned 1 exit status > error: command 'gcc' failed with exit status 1 > > Anyway, there is a file libmapserver.la in the source directory. > > What is it, that I'm mising? > > Thanks, > > Peter > > -- > Peter Hopfgartner > web : http://www.r3-gis.com > > ______________________________**_________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.**org > http://lists.osgeo.org/**mailman/listinfo/mapserver-**users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Marc-Andre.Morin at dfo-mpo.gc.ca Fri Apr 27 08:53:42 2012 From: Marc-Andre.Morin at dfo-mpo.gc.ca (Marc-Andre Morin) Date: Fri, 27 Apr 2012 08:53:42 -0700 (PDT) Subject: [mapserver-users] Re: Projection issue with vrt file In-Reply-To: <33E3342755CFC844901AD4572AD514A4039E4655@lauqueex01.lau.dfo-mpo.ca> References: <33E3342755CFC844901AD4572AD514A4039E4655@lauqueex01.lau.dfo-mpo.ca> Message-ID: <1335542022016-4934316.post@n6.nabble.com> Hi Frank, Thanks for your reply. I've made some tests and got some more details about this issue: 1- If I translate my BSB file (KAP format) to Geotiff format, this geotiff file is well shown and georeferenced at the right place if I use it directly: DATA "BSB/KAP/131701.kap.warped.tiff" PROJECTION 'proj=merc' 'lon_0=-70' 'k=1' 'x_0=0' 'y_0=0' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'units=m' 'no_defs' END Command line to generate the geotiff file: gdal_translate 131701.kap 131701.kap.ori.tiff gdalwarp 131701.kap.ori.tiff 131701.kap.warped.tiff Gdalinfo... E:\ms4w\apps\marinfo\data\BSB\KAP>gdalinfo 131701.kap.warped.tiff Driver: GTiff/GeoTIFF Files: 131701.kap.warped.tiff Size is 11387, 8093 Coordinate System is: PROJCS["Global Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.257223563, AUTHORITY["EPSG","7030"]], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0], UNIT["degree",0.0174532925199433], AUTHORITY["EPSG","4326"]], PROJECTION["Mercator_1SP"], PARAMETER["central_meridian",-70], PARAMETER["scale_factor",1], PARAMETER["false_easting",0], PARAMETER["false_northing",0], UNIT["metre",1, AUTHORITY["EPSG","9001"]]] Origin = (-107047.991228487620000,5945211.986471482600000) Pixel Size = (7.342576435115765,-7.342576435115765) Metadata: AREA_OR_POINT=Area Image Structure Metadata: INTERLEAVE=BAND Corner Coordinates: Upper Left ( -107047.991, 5945211.986) ( 70d57'41.86"W, 47d12'39.62"N) Lower Left ( -107047.991, 5885788.515) ( 70d57'41.86"W, 46d50'45.62"N) Upper Right ( -23438.073, 5945211.986) ( 70d12'37.97"W, 47d12'39.62"N) Lower Right ( -23438.073, 5885788.515) ( 70d12'37.97"W, 46d50'45.62"N) Center ( -65243.032, 5915500.251) ( 70d35'9.92"W, 47d 1'43.75"N) Band 1 Block=11387x1 Type=Byte, ColorInterp=Palette Color Table (RGB with 256 entries) 0: 0,0,0,255 ... 2- Now, the VRT file that I try to generate and use comes from the tilers_tools' python script called map2gdal.py http://code.google.com/p/tilers-tools/ The big advantage with this VRT file is the fact that this VRT file points directly to my KAP file, and all metadata related to this file are extracted and available for future processes... This VRT file looks like this: +proj=merc +lat_ts=47.166667 +datum=NAD83 +nodefs -5.3802490306424974e+006, 5.0001511315648770e+000,-1.8211665160056521e-004, 4.0492551038299361e+006,-2.5595698020313497e-004,-5.0010081232801378e+000 SC=50000,GD=NAD83,PR=MERCATOR,PP=47.166667,PI=5.000000,SP=,SK=0.000000,TA=90.000000,UN=METRES,SD=LNT,DX=5.000000,DY=5.000000 EC=RF,GD=NAR,VC=ZZZ,SC=ZZZ,PC=MC,P1=-70.582029,P2=47.166667,P3=0.0,P4=NOT_APPLICABLE,GC=GE,RM=NONE MULTIPOLYGON(((257.76284645559468 7745.7076975815671,2490.025011025306 7746.5301512821934,2492.2163879532559 7181.6425479723066,3276.1412438760321 7210.5951029770404,4429.0270760545409 6817.9091369725729,4890.9737230091405 6736.5650032022368,11250.811878184026 354.19735628215676,11251.785400765162 244.45756921568665,3537.7418346315158 244.33482436588929,3523.5069250460119 2029.8367618071302,1881.7430005409099 2028.8818991008357,1868.6640235103462 2447.8575431625686,258.92730402280057 2434.9666589315798))) SAULT-AU-COCHON ?/TO QU?BEC ... Palette E:\ms4w\apps\marinfo\data\BSB\KAP\131701.kap 1 If I change the mapfile to now point on my VRT file... DATA "BSB/KAP/131701.vrt" PROJECTION 'proj=merc' 'lon_0=-70' 'k=1' 'x_0=0' 'y_0=0' 'ellps=WGS84' 'towgs84=0,0,0,0,0,0,0' 'units=m' 'no_defs' END ... Nothing appears on the map. 3- If I change the GeoTransform element by the one generated with gdal from the geotiff file gdalbuildvrt 131701.vrt 131701.kap.warped.tiff 131701.vrt: PROJCS["Global Mercator",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]],PROJECTION["Mercator_1SP"],PARAMETER["central_meridian",-70],PARAMETER["scale_factor",1],PARAMETER["false_easting",0],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]]] -1.0704799122848762e+005, 7.3425764351157650e+000, 0.0000000000000000e+000, 5.9452119864714826e+006, 0.0000000000000000e+000,-7.3425764351157650e+000 Palette ... 131701.kap.warped.tiff 1 So the new VRT file will look like this: +proj=merc +lat_ts=47.166667 +datum=NAD83 +nodefs -1.0704799122848762e+005, 7.3425764351157650e+000, 0.0000000000000000e+000, 5.9452119864714826e+006, 0.0000000000000000e+000,-7.3425764351157650e+000 SC=50000,GD=NAD83,PR=MERCATOR,PP=47.166667,PI=5.000000,SP=,SK=0.000000,TA=90.000000,UN=METRES,SD=LNT,DX=5.000000,DY=5.000000 EC=RF,GD=NAR,VC=ZZZ,SC=ZZZ,PC=MC,P1=-70.582029,P2=47.166667,P3=0.0,P4=NOT_APPLICABLE,GC=GE,RM=NONE MULTIPOLYGON(((257.76284645559468 7745.7076975815671,2490.025011025306 7746.5301512821934,2492.2163879532559 7181.6425479723066,3276.1412438760321 7210.5951029770404,4429.0270760545409 6817.9091369725729,4890.9737230091405 6736.5650032022368,11250.811878184026 354.19735628215676,11251.785400765162 244.45756921568665,3537.7418346315158 244.33482436588929,3523.5069250460119 2029.8367618071302,1881.7430005409099 2028.8818991008357,1868.6640235103462 2447.8575431625686,258.92730402280057 2434.9666589315798))) SAULT-AU-COCHON ?/TO QU?BEC ... D:\ms4w\apps\marinfo\data\BSB\KAP\131701.kap ... And now, the BSB file is shown properly... Why? Is it because the BSB geotransform element has originally a rotation in the matrix, that is eliminated when the warped geotiff file is generated? Effectively, if I try to generate a VRT file from my original BSB file, I get the following warning: E:\ms4w\apps\marinfo\data\BSB\KAP>gdalbuildvrt 131701.vrt 131701.kap 0...10...20...30...40...50...60...70...80...90...100 - done. Warning 6: gdalbuildvrt does not support rotated geo transforms. Skipping 131701 .kap Any help on this will be appreciated. Regards, Marc-Andr? -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Projection-issue-with-vrt-file-tp4903846p4934316.html Sent from the Mapserver - User mailing list archive at Nabble.com. From Bob.Basques at ci.stpaul.mn.us Fri Apr 27 09:15:10 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Fri, 27 Apr 2012 11:15:10 -0500 Subject: [mapserver-users] Imagemap making . . . Message-ID: <4F9A7FBE020000A800035B3E@heckle> All, So, I'm trying to make an imagemap of line segments that are all only two vertices long. (two-point line strings) from postgres, I've verified this with to_NumPoints on both of the features described below. This same template process works fine with SHP files. I have to be missing something obvious. Using this call(which grabs two of the segments): http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/trails_segments_public.map?mapext=555266.1928265226%20157102.55366815554%20577346.2664937055%20170723.37833297616&mapsize=924%20570&mode=nquery&searchmap=true&veh_id=2153&time_idx1=4/24/2012%209:55:00&time_idx2=4/24/2012%209:56:00 and that generates this SQL: select "esn","veh_id","time_idx1","time_idx2","time_interval","time_diff_secs","dist","gps_speed1","gps_speed2","calc_speed","bearing",encode(AsBinary(force_collection(force_2d("the_geom")),'NDR'),'hex') as geom,"veh_id" from public.stmaint_trails_segments as t where the_geom && GeomFromText('POLYGON((555258.759391547 157102.553668156,555258.759391547 170723.378332976,577353.699928681 170723.378332976,577353.699928681 157102.553668156,555258.759391547 157102.553668156))',200068) and ( veh_id like '2153' AND time_idx1 > '4/24/2012 9:55:00' AND time_idx2 <'4/24/2012 9:56:00') and SQL result: 11031823;"2153";"2012-04-24 09:55:13-05";"2012-04-24 09:55:31-05";"00:00:18";"18";474.708833608277;15.9;18.9;17.9813952124347;356.698784312184;"0107000000010000000102000000020000009aec99afc035214144b128eb9c430341158476038a3521411f0e92496c520341";"2153" 11031823;"2153";"2012-04-24 09:55:31-05";"2012-04-24 09:55:50-05";"00:00:19";"19";474.002298490239;18.9;13.1;17.0096518596976;359.825436952247;"010700000001000000010200000002000000158476038a3521411f0e92496c52034199201020873521413bbac5493c610341";"2153" from this TEMPLATE: ID: [veh_id] [esn] [time_idx2] [calc_speed] [bearing] [dist] [time_interval] I get this as output: VehiclesID: 2153 11031823 2012-04-24 09:55:31-05 17.9813952124347 356.698784312184 474.708833608277 00:00:18ID: 2153 11031823 2012-04-24 09:55:50-05 17.0096518596976 359.825436952247 474.002298490239 00:00:19Where the heck are all those COORD values coming from, shouldn't there only be four (4) point pairs per feature (or is it five, repeat last point)?Thanksbobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Fri Apr 27 09:18:19 2012 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Fri, 27 Apr 2012 11:18:19 -0500 Subject: [mapserver-users] Imagemap making . . . (last post didn't format very well., sorry . . .) Message-ID: <4F9A807B020000A800035B43@heckle> All, So, I'm trying to make an imagemap of line segments that are all only two vertices long. (two-point line strings) from postgres, I've verified this with to_NumPoints on both of the features described below. This same template process works fine with SHP files. I have to be missing something obvious. Using this call(which grabs two of the segments): http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/trails_segments_public.map?mapext=555266.1928265226%20157102.55366815554%20577346.2664937055%20170723.37833297616&mapsize=924%20570&mode=nquery&searchmap=true&veh_id=2153&time_idx1=4/24/2012%209:55:00&time_idx2=4/24/2012%209:56:00 and that generates this SQL: select "esn","veh_id","time_idx1","time_idx2","time_interval","time_diff_secs","dist","gps_speed1","gps_speed2","calc_speed","bearing",encode(AsBinary(force_collection(force_2d("the_geom")),'NDR'),'hex') as geom,"veh_id" from public.stmaint_trails_segments as t where the_geom && GeomFromText('POLYGON((555258.759391547 157102.553668156,555258.759391547 170723.378332976,577353.699928681 170723.378332976,577353.699928681 157102.553668156,555258.759391547 157102.553668156))',200068) and ( veh_id like '2153' AND time_idx1 > '4/24/2012 9:55:00' AND time_idx2 <'4/24/2012 9:56:00') and SQL result: 11031823;"2153";"2012-04-24 09:55:13-05";"2012-04-24 09:55:31-05";"00:00:18";"18";474.708833608277;15.9;18.9;17.9813952124347;356.698784312184;"0107000000010000000102000000020000009aec99afc035214144b128eb9c430341158476038a3521411f0e92496c520341";"2153" 11031823;"2153";"2012-04-24 09:55:31-05";"2012-04-24 09:55:50-05";"00:00:19";"19";474.002298490239;18.9;13.1;17.0096518596976;359.825436952247;"010700000001000000010200000002000000158476038a3521411f0e92496c52034199201020873521413bbac5493c610341";"2153" from this TEMPLATE: ID: [veh_id] [esn] [time_idx2] [calc_speed] [bearing] [dist] [time_interval] I get this as output: VehiclesID: 2153 11031823 2012-04-24 09:55:31-05 17.9813952124347 356.698784312184 474.708833608277 00:00:18ID: 2153 11031823 2012-04-24 09:55:50-05 17.0096518596976 359.825436952247 474.002298490239 00:00:19 Where the heck are all those COORD values coming from, shouldn't there only be four (4) point pairs per feature (or is it five, repeat last point)?Thanksbobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at state.mn.us Fri Apr 27 09:42:20 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Fri, 27 Apr 2012 16:42:20 +0000 Subject: [mapserver-users] Imagemap making . . . (last post didn't format very well., sorry . . .) In-Reply-To: <4F9A807B020000A800035B43@heckle> References: <4F9A807B020000A800035B43@heckle> Message-ID: If you just do a plain [shpxy] in a comment or something what do see? From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Friday, April 27, 2012 11:18 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Imagemap making . . . (last post didn't format very well., sorry . . .) All, So, I'm trying to make an imagemap of line segments that are all only two vertices long. (two-point line strings) from postgres, I've verified this with to_NumPoints on both of the features described below. This same template process works fine with SHP files. I have to be missing something obvious. Using this call(which grabs two of the segments): http://gis.ci.stpaul.mn.us/datasets/DB/SAINT_PAUL/PUBLIC_WORKS/AVL/STREETS/trails_segments_public.map?mapext=555266.1928265226%20157102.55366815554%20577346.2664937055%20170723.37833297616&mapsize=924%20570&mode=nquery&searchmap=true&veh_id=2153&time_idx1=4/24/2012%209:55:00&time_idx2=4/24/2012%209:56:00 and that generates this SQL: select "esn","veh_id","time_idx1","time_idx2","time_interval","time_diff_secs","dist","gps_speed1","gps_speed2","calc_speed","bearing",encode(AsBinary(force_collection(force_2d("the_geom")),'NDR'),'hex') as geom,"veh_id" from public.stmaint_trails_segments as t where the_geom && GeomFromText('POLYGON((555258.759391547 157102.553668156,555258.759391547 170723.378332976,577353.699928681 170723.378332976,577353.699928681 157102.553668156,555258.759391547 157102.553668156))',200068) and ( veh_id like '2153' AND time_idx1 > '4/24/2012 9:55:00' AND time_idx2 <'4/24/2012 9:56:00') and SQL result: 11031823;"2153";"2012-04-24 09:55:13-05";"2012-04-24 09:55:31-05";"00:00:18";"18";474.708833608277;15.9;18.9;17.9813952124347;356.698784312184;"0107000000010000000102000000020000009aec99afc035214144b128eb9c430341158476038a3521411f0e92496c520341";"2153" 11031823;"2153";"2012-04-24 09:55:31-05";"2012-04-24 09:55:50-05";"00:00:19";"19";474.002298490239;18.9;13.1;17.0096518596976;359.825436952247;"010700000001000000010200000002000000158476038a3521411f0e92496c52034199201020873521413bbac5493c610341";"2153" from this TEMPLATE: ID: [veh_id] [esn] [time_idx2] [calc_speed] [bearing] [dist] [time_interval] I get this as output: VehiclesID: 2153 11031823 2012-04-24 09:55:31-05 17.9813952124347 356.698784312184 474.708833608277 00:00:18ID: 2153 11031823 2012-04-24 09:55:50-05 17.0096518596976 359.825436952247 474.002298490239 00:00:19 Where the heck are all those COORD values coming from, shouldn't there only be four (4) point pairs per feature (or is it five, repeat last point)?Thanksbobb -------------- next part -------------- An HTML attachment was scrubbed... URL: From anajera at bicimapas.com.mx Fri Apr 27 11:19:22 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Fri, 27 Apr 2012 13:19:22 -0500 Subject: [mapserver-users] Open Layers Problem Message-ID: <001101cd24a2$46200d60$d2602820$@com.mx> Hello We have a map that is rendered well using the Mapserver template and are trying to use it with OpenLayers but are experiencing some problems as the map does not show and I cannot find why. We are using a Linux Centos 5 remote server and the map file is located in home/bicimapas/mapdata/BiciMapasMS.map and the Mapserver CGI is located in /home/bicimapas/cgi-bin/mapserv. The IP address is 173.236.45.118 On the map file we added this Metadata lines under the WEB section METADATA "wms_title" "BiciMapasMS" "wms_onlineresource" "http://173.236.45.118/cgi-bin/mapserv?map=http://173.236.45.118/home/bicima pas/mapdata/BiciMapasMS.map&" "wms_srs" "EPSG:4326" "wms_enable_request" "*" END And the metadata for the test layer was added like this LAYER NAME "areaurbana" DATA "AreasMS" STATUS on TYPE polygon LABELCACHE on LABELITEM "NAME" CLASSITEM "CATEGORY" METADATA "wms_title" "areaurbana" "wms_srs" "EPSG:4326" "wms_include_items" "all" END (more code here...........) Finally, the code being used to make the Openlayers call is: Open Layers Test

Thanks in advance for your help Alberto Najera ? From pcreso at pcreso.com Fri Apr 27 11:36:42 2012 From: pcreso at pcreso.com (pcreso at pcreso.com) Date: Fri, 27 Apr 2012 11:36:42 -0700 (PDT) Subject: [mapserver-users] elevation profile In-Reply-To: <950B4E25-E855-4786-86E6-347A8E1C9923@gmail.com> Message-ID: <1335551802.99354.YahooMailClassic@web160705.mail.bf1.yahoo.com> Hi Puneet I suggest you use GMT - the best open source cartographic & grid analysis tool available!? http://gmt.soest.hawaii.edu you may need your SRTM surface as a GMT netCDF grid, which GDAL supports nicely, or you may be able to describe your SRTM grid for GMT to use natively - I'm not sure the project command will generate your line, with sample points along it as straight or great circle lines between end points grdtrack will turn your XY line coordinates into xyz values, with the Z values derived from your SRTM grid psxy will gernerate a nicely annotated graphic (postscript) showing your profile psxyz can (alternatively) render your profile in 3d space (overlaid on a 3D perspective view of the surface if required) ps2raster will convert to a raster image such as png. This can easily be wrapped up in a cgi if required. Cheers, ??? Brent Wood --- On Fri, 4/27/12, Puneet Kishor wrote: From: Puneet Kishor Subject: Re: [mapserver-users] elevation profile To: "Stephen Woodbridge" Cc: mapserver-users at lists.osgeo.org Date: Friday, April 27, 2012, 2:49 PM On Apr 26, 2012, at 7:20 PM, Stephen Woodbridge wrote: > On 4/26/2012 7:35 PM, Puneet Kishor wrote: >> Any suggestions on how something like this could be implemented using MapServer? >> >> http://viewer.nationalmap.gov/example/elevation_profile.html >> >> >> My front-end is OpenLayers, and the backend data are from SRTM. I'd like to click on the map and create a line, and get back the elevation numbers for that line. I only want the elevation numbers as I can optionally construct the profile via a variety of ways. >> >> I am assuming I could send a line WKT, but how would I query for the values using MapServer? >> >> Fwiw, http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html seems to use a canvas implementation that doesn't seem to be available in my standard-issue OL 2.11. Calling `this.layer.getPixelDataForViewPortPx` croaks with "not a function" message. In any case, I don't really want the RGB values under the mouse. I want the actual height values. >> >> Thanks in advance for any suggestions, > > Hi Puneet, > > I have done this in the past and there are a bunch of moving parts. Here is what I did. > > 1. got a copy of NED2 data for the US. > 2. create a gdal .vrt file to pull all the files into a single virtual file > 3. wrote a simple C fcgi program to take an x,y and get the elevation from the the NED2 data. > > http://imaptools.com:8080/cgi-bin/getElevation.fcgi?lat=32.662864999999996&lon=-86.880096999999992 > > 4. I used pgRouting to compute a route and then took the route geometry and added sample point along the edges where needed, and hit the fcgi service to convert the points to elevations and then plotted the elevations against the their length along the line that the x,y represented. > > I also think I may have wrote an app where you could pass the route polyline to it an it would generate an image of the elevation plot. > > 5. Then wired it into the web page as an ajax call of as a image url that gets updated. > Thanks for the details, Steve. All this is way more complicated that I was envisioning. And, PostGIS 2 is out of the question, for now, at least. Could you send me that gdal .vrt file? I'd like to look at it. Perhaps that will give me some other ideas on how to approach this. Many thanks, -- Puneet Kishor _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From David.Fawcett at state.mn.us Fri Apr 27 11:30:45 2012 From: David.Fawcett at state.mn.us (Fawcett, David (MPCA)) Date: Fri, 27 Apr 2012 18:30:45 +0000 Subject: [mapserver-users] elevation profile In-Reply-To: <4F9A150C.3060301@swoodbridge.com> References: <4F99E65C.7060504@swoodbridge.com> <950B4E25-E855-4786-86E6-347A8E1C9923@gmail.com> <4F9A150C.3060301@swoodbridge.com> Message-ID: It would likely not be as efficient, but you could also utilize an elevation service for that part of it: http://cumulus.cr.usgs.gov/XMLWebServices2/Elevation_Service.asmx http://developer.mapquest.com/web/products/open/elevation-service -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Stephen Woodbridge Sent: Thursday, April 26, 2012 10:40 PM To: Puneet Kishor Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] elevation profile On 4/26/2012 10:49 PM, Puneet Kishor wrote: > > On Apr 26, 2012, at 7:20 PM, Stephen Woodbridge wrote: > >> On 4/26/2012 7:35 PM, Puneet Kishor wrote: >>> Any suggestions on how something like this could be implemented >>> using MapServer? >>> >>> http://viewer.nationalmap.gov/example/elevation_profile.html >>> >>> >>> My front-end is OpenLayers, and the backend data are from SRTM. >>> I'd like to click on the map and create a line, and get back the >>> elevation numbers for that line. I only want the elevation >>> numbers as I can optionally construct the profile via a variety >>> of ways. >>> >>> I am assuming I could send a line WKT, but how would I query for >>> the values using MapServer? >>> >>> Fwiw, >>> http://dev.openlayers.org/sandbox/camptocamp/canvas/openlayers/examples/elevationCanvas.html >>> seems to use a canvas implementation that doesn't seem to be >>> available in my standard-issue OL 2.11. Calling >>> `this.layer.getPixelDataForViewPortPx` croaks with "not a >>> function" message. In any case, I don't really want the RGB >>> values under the mouse. I want the actual height values. >>> >>> Thanks in advance for any suggestions, >> >> Hi Puneet, >> >> I have done this in the past and there are a bunch of moving parts. >> Here is what I did. >> >> 1. got a copy of NED2 data for the US. 2. create a gdal .vrt file >> to pull all the files into a single virtual file 3. wrote a simple >> C fcgi program to take an x,y and get the elevation from the the >> NED2 data. >> >> http://imaptools.com:8080/cgi-bin/getElevation.fcgi?lat=32.662864999999996&lon=-86.880096999999992 >> >> >> 4. I used pgRouting to compute a route and then took the route geometry and added sample point along the edges where needed, and hit the fcgi service to convert the points to elevations and then plotted the elevations against the their length along the line that the x,y represented. >> >> I also think I may have wrote an app where you could pass the route >> polyline to it an it would generate an image of the elevation >> plot. >> >> 5. Then wired it into the web page as an ajax call of as a image >> url that gets updated. >> > > > > Thanks for the details, Steve. All this is way more complicated that > I was envisioning. And, PostGIS 2 is out of the question, for now, at > least. > > Could you send me that gdal .vrt file? I'd like to look at it. > Perhaps that will give me some other ideas on how to approach this. Puneet, GDAL has a utility gdalbuildvrt the creates the .vrt file I think I ran it something like: gdalbuildvrt ned2.vrt /u/data/ned2/*.tif run gdalbuildvrt with no arguments to get some help. If you want you could use mapserver and set up a point query against the ned2 data to get the elevation, then write a php wrapper to take the polyline and sample it and call mapserver to get the elevations along the polyline and you the php gd code to plot it out. -Steve _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From anajera at bicimapas.com.mx Fri Apr 27 15:48:00 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Fri, 27 Apr 2012 17:48:00 -0500 Subject: [mapserver-users] Open Layers Problem In-Reply-To: <001101cd24a2$46200d60$d2602820$@com.mx> References: <001101cd24a2$46200d60$d2602820$@com.mx> Message-ID: <005601cd24c7$cd42a080$67c7e180$@com.mx> I tested the WMS capabilities with this string http://173.236.45.118/cgi-bin/mapserv?map=BiciMapasMS.map&SERVICE=WMS&VERSIO N=1.1.1&REQUEST=GetCapabilities and get this message msLoadMap(): Unable to access file. (BiciMapasMS.map) Why would the map file not be accessible to openlayers while Mapserver can access it? Is it a permissions or a path definition problem? Any hel os appreciated. Thanks Alberto Najera -----Mensaje original----- De: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] En nombre de Alberto Najera Enviado el: viernes, 27 de abril de 2012 01:19 p.m. Para: mapserver-users at lists.osgeo.org Asunto: [mapserver-users] Open Layers Problem Hello We have a map that is rendered well using the Mapserver template and are trying to use it with OpenLayers but are experiencing some problems as the map does not show and I cannot find why. We are using a Linux Centos 5 remote server and the map file is located in home/bicimapas/mapdata/BiciMapasMS.map and the Mapserver CGI is located in /home/bicimapas/cgi-bin/mapserv. The IP address is 173.236.45.118 On the map file we added this Metadata lines under the WEB section METADATA "wms_title" "BiciMapasMS" "wms_onlineresource" "http://173.236.45.118/cgi-bin/mapserv?map=http://173.236.45.118/home/bicima pas/mapdata/BiciMapasMS.map&" "wms_srs" "EPSG:4326" "wms_enable_request" "*" END And the metadata for the test layer was added like this LAYER NAME "areaurbana" DATA "AreasMS" STATUS on TYPE polygon LABELCACHE on LABELITEM "NAME" CLASSITEM "CATEGORY" METADATA "wms_title" "areaurbana" "wms_srs" "EPSG:4326" "wms_include_items" "all" END (more code here...........) Finally, the code being used to make the Openlayers call is: Open Layers Test
Thanks in advance for your help Alberto Najera ? _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From anajera at bicimapas.com.mx Fri Apr 27 16:25:30 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Fri, 27 Apr 2012 18:25:30 -0500 Subject: [mapserver-users] Open Layers Problem In-Reply-To: <4F9B28F2.3050308@umb.no> References: <001101cd24a2$46200d60$d2602820$@com.mx> <005601cd24c7$cd42a080$67c7e180$@com.mx> <4F9B28F2.3050308@umb.no> Message-ID: <005d01cd24cd$0a443430$1ecc9c90$@com.mx> Thanks, I used this http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetCapabilities and now get the capabilities report, which seems to be correct, but still the map does not show with OpenLayers. Any ideas? Alberto Najera www.bicimapas.com.mx www.bicimapas.com.mx/Empresa.htm Avenida Lomas Verdes No. 58, Local 17 Colonia Santa Cruz Acatl?n Naucalpan, Estado de M?xico M?xico CP 53150 Tel: (55) 53 60 30 65 anajera at bicimapas.com.mx ? B?scanos como Bicimapas ? -----Mensaje original----- De: Havard Tveite [mailto:havard.tveite at umb.no] Enviado el: viernes, 27 de abril de 2012 06:17 p.m. Para: Alberto Najera Asunto: Re: [mapserver-users] Open Layers Problem Try using the complete (absolute) path to the mapfile. H?vard On 28/04/12 00:48, Alberto Najera wrote: > I tested the WMS capabilities with this string > > http://173.236.45.118/cgi-bin/mapserv?map=BiciMapasMS.map&SERVICE=WMS& > VERSIO > N=1.1.1&REQUEST=GetCapabilities > > and get this message > > msLoadMap(): Unable to access file. (BiciMapasMS.map) > > Why would the map file not be accessible to openlayers while Mapserver > can access it? Is it a permissions or a path definition problem? > > Any hel os appreciated. Thanks > > > Alberto Najera > > > -----Mensaje original----- > De: mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] En nombre de Alberto > Najera Enviado el: viernes, 27 de abril de 2012 01:19 p.m. > Para: mapserver-users at lists.osgeo.org > Asunto: [mapserver-users] Open Layers Problem > > Hello > > We have a map that is rendered well using the Mapserver template and > are trying to use it with OpenLayers but are experiencing some > problems as the map does not show and I cannot find why. > > We are using a Linux Centos 5 remote server and the map file is > located in home/bicimapas/mapdata/BiciMapasMS.map and the Mapserver > CGI is located in /home/bicimapas/cgi-bin/mapserv. The IP address is > 173.236.45.118 > > On the map file we added this Metadata lines under the WEB section > > METADATA > "wms_title" "BiciMapasMS" > "wms_onlineresource" > "http://173.236.45.118/cgi-bin/mapserv?map=http://173.236.45.118/home/ > bicima > pas/mapdata/BiciMapasMS.map&" > "wms_srs" "EPSG:4326" > "wms_enable_request" "*" > END > > > And the metadata for the test layer was added like this > > LAYER > NAME "areaurbana" > DATA "AreasMS" > STATUS on > TYPE polygon > LABELCACHE on > LABELITEM "NAME" > CLASSITEM "CATEGORY" > METADATA > "wms_title" "areaurbana" > "wms_srs" "EPSG:4326" > "wms_include_items" "all" > END > (more code here...........) > > Finally, the code being used to make the Openlayers call is: > > > > > > Open Layers Test > > > > > >
>
> > > > Thanks in advance for your help > > Alberto Najera From pcreso at pcreso.com Fri Apr 27 17:26:11 2012 From: pcreso at pcreso.com (pcreso at pcreso.com) Date: Fri, 27 Apr 2012 17:26:11 -0700 (PDT) Subject: [mapserver-users] Open Layers Problem In-Reply-To: <005d01cd24cd$0a443430$1ecc9c90$@com.mx> Message-ID: <1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com> Hi Alberto, I can get the capabilities document, & a list of available layers, using the WMS facility in Quantum GIS, but when I try to access/load the layers as a map the request fails: "Response: MapServer Message msLoadMap(): Unable to access file. (http://173.236.45.118/home/bicimapas/mapdata/BiciMapasMS.map) " I suggest that having your mapfile in your home directory tree rather than your webserver's directory tree might be the problem. You might also try tools like uDIG or QGIS to access the WMS service & debug it before you try to get it working with OpenLayers. Cheers, ?? Brent Wood --- On Sat, 4/28/12, Alberto Najera wrote: From: Alberto Najera Subject: RE: [mapserver-users] Open Layers Problem To: mapserver-users at lists.osgeo.org Date: Saturday, April 28, 2012, 11:25 AM Thanks, I used this http://173.236.45.118/cgi-bin/mapserv?map=BiciMapasMS.map&SERVICE=WMS& > VERSIO > N=1.1.1&REQUEST=GetCapabilities > > and get this message > > msLoadMap(): Unable to access file. (BiciMapasMS.map) > > Why would the map file not be accessible to openlayers while Mapserver > can access it?? Is it a permissions or a path definition problem? > > Any hel os appreciated. Thanks > > > Alberto Najera > > > -----Mensaje original----- > De: mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] En nombre de Alberto > Najera Enviado el: viernes, 27 de abril de 2012 01:19 p.m. > Para: mapserver-users at lists.osgeo.org > Asunto: [mapserver-users] Open Layers Problem > > Hello > > We have a map that is rendered well using the Mapserver template and > are trying to use it with OpenLayers but are experiencing some > problems as the map does not show and I cannot find why. > > We are using a Linux Centos 5 remote server and the map file is > located in home/bicimapas/mapdata/BiciMapasMS.map and the Mapserver > CGI? is located in /home/bicimapas/cgi-bin/mapserv. The IP address is? > 173.236.45.118 > > On the map file we added this Metadata lines under the WEB section > > METADATA >? ? ? "wms_title" "BiciMapasMS" >? ? ? "wms_onlineresource" > " -------------- next part -------------- An HTML attachment was scrubbed... URL: From anajera at bicimapas.com.mx Fri Apr 27 20:17:27 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Fri, 27 Apr 2012 22:17:27 -0500 Subject: [mapserver-users] Open Layers Problem In-Reply-To: <1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com> References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx> <1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com> Message-ID: <000001cd24ed$7d0ac7c0$77205740$@com.mx> Brent, Thanks for testing it. The "home/bicimapas/" path is the webserver directory tree. As a fact this same test map works well using the Mapserver templates as you can test with this link http://173.236.45.118/bcmpms_i.html which is the initialization page. Press "Acceder" and you will be taken to the map. The question here is why can the Mapserver template can access the file while OpenLayers does not. Is there a reference document or tutorial on how to properly set up OpenLayers to work with Mapserver? Alberto Najera De: pcreso at pcreso.com [mailto:pcreso at pcreso.com] Enviado el: viernes, 27 de abril de 2012 07:26 p.m. Para: mapserver-users at lists.osgeo.org; Alberto Najera Asunto: RE: [mapserver-users] Open Layers Problem Hi Alberto, I can get the capabilities document, & a list of available layers, using the WMS facility in Quantum GIS, but when I try to access/load the layers as a map the request fails: "Response: MapServer Message msLoadMap(): Unable to access file. (http://173.236.45.118/home/bicimapas/mapdata/BiciMapasMS.map) " I suggest that having your mapfile in your home directory tree rather than your webserver's directory tree might be the problem. You might also try tools like uDIG or QGIS to access the WMS service & debug it before you try to get it working with OpenLayers. Cheers, Brent Wood -------------- next part -------------- An HTML attachment was scrubbed... URL: From mmypost at yandex.ru Sat Apr 28 01:46:32 2012 From: mmypost at yandex.ru (mmypost mmypost) Date: Sat, 28 Apr 2012 12:46:32 +0400 Subject: [mapserver-users] How I get image high quality for print? Message-ID: <309191335602792@web16g.yandex.ru> Hi! Sorry for my bad English. I have a problem with image quality. I create image by mapserver and then print it. I set 300dpi resolution, but some truetype symbols was not visible in image (if image 96 dpi or default resolution,then the truetype symbols is visible). Some symbols has poor quality. I attempted to create images with different size. Can I to get high quality image for print? Version mapserver 6.2 Yours sincerely, Sev From Jukka.Rahkonen at mmmtike.fi Sat Apr 28 02:24:23 2012 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Sat, 28 Apr 2012 09:24:23 +0000 Subject: [mapserver-users] How I get image high quality for print? In-Reply-To: <309191335602792@web16g.yandex.ru> References: <309191335602792@web16g.yandex.ru> Message-ID: <84446DEF76453C439E9E97E438E13A6314C19B@suutari.haapa.mmm.fi> Hi, Try map_resolution parameter. There is an example images at last pages of document http://latuviitta.org/documents/Super_easy_WMS_server.pdf -Jukka Rahkonen- mmypost wrote: > Hi! > Sorry for my bad English. > I have a problem with image quality. I create image by mapserver and then print it. I set 300dpi resolution, but some truetype symbols was not visible in image (if image 96 dpi or default resolution,then the truetype symbols is visible). Some symbols has poor quality. I attempted to create images with different size. Can I to get high quality image for print? Version mapserver 6.2 Yours sincerely, Sev _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From matt at wildwalks.com Sat Apr 28 05:44:59 2012 From: matt at wildwalks.com (Matt McClelland) Date: Sat, 28 Apr 2012 22:44:59 +1000 Subject: [mapserver-users] Really slow map creation from POSTGIS DB Message-ID: Hi All I have a set of contours in a SHP file If I point my map file to the SHP file I can generate a WMS image in under 1 second Shp file is just shy of 200MB I then use shp2pgsql to load the same dataset into the DB I added an index for the_geom And am requesting the data in the mapfile using the same EPSG The map draws correclty but is now taking about 30secs when using the DB. Any ideas on how to make it faster. Thanks Matt :) -------------- next part -------------- An HTML attachment was scrubbed... URL: From woodbri at swoodbridge.com Sat Apr 28 06:20:42 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Sat, 28 Apr 2012 09:20:42 -0400 Subject: [mapserver-users] Really slow map creation from POSTGIS DB In-Reply-To: References: Message-ID: <4F9BEEAA.7000903@swoodbridge.com> On 4/28/2012 8:44 AM, Matt McClelland wrote: > Hi All > > I have a set of contours in a SHP file > If I point my map file to the SHP file I can generate a WMS image in > under 1 second > Shp file is just shy of 200MB > > I then use shp2pgsql to load the same dataset into the DB > I added an index for the_geom > And am requesting the data in the mapfile using the same EPSG > > The map draws correclty but is now taking about 30secs when using the DB. > > Any ideas on how to make it faster. Simplify the data for the that zoom level. If you are all the way zoomed out and drawing all the data, then the shapefile will be fastest. An index does not help if you are drawing all the data as you need to do a full table scan anyway to get all the records. It is simply faster to read 200MB from disk than from the database because the database has to fetch the same data and may have to jump through some hoops to get it out of extended storage, then it has to encode the data and send it over the connection and the client has to decode the data. Do you really need all the resolution of the data at this scale? If not create another column and simplify the geometry into that column and set up your mapfile to query the simplified data at this zoom and to query the detailed data as you zoom in. -Steve W From punk.kish at gmail.com Sat Apr 28 06:44:27 2012 From: punk.kish at gmail.com (Puneet Kishor) Date: Sat, 28 Apr 2012 08:44:27 -0500 Subject: [mapserver-users] Really slow map creation from POSTGIS DB In-Reply-To: <4F9BEEAA.7000903@swoodbridge.com> References: <4F9BEEAA.7000903@swoodbridge.com> Message-ID: On Apr 28, 2012, at 8:20 AM, Stephen Woodbridge wrote: > On 4/28/2012 8:44 AM, Matt McClelland wrote: >> Hi All >> >> I have a set of contours in a SHP file >> If I point my map file to the SHP file I can generate a WMS image in >> under 1 second >> Shp file is just shy of 200MB >> >> I then use shp2pgsql to load the same dataset into the DB >> I added an index for the_geom >> And am requesting the data in the mapfile using the same EPSG >> >> The map draws correclty but is now taking about 30secs when using the DB. >> >> Any ideas on how to make it faster. > > Simplify the data for the that zoom level. > > If you are all the way zoomed out and drawing all the data, then the shapefile will be fastest. An index does not help if you are drawing all the data as you need to do a full table scan anyway to get all the records. It is simply faster to read 200MB from disk than from the database because the database has to fetch the same data and may have to jump through some hoops to get it out of extended storage, then it has to encode the data and send it over the connection and the client has to decode the data. > > Do you really need all the resolution of the data at this scale? If not create another column and simplify the geometry into that column and set up your mapfile to query the simplified data at this zoom and to query the detailed data as you zoom in. All of the above is great advice. Additionally, implement a tilecache server; why redraw an image if it has already been drawn. That said, while a db is going to be slower than the file system in many cases, there are many reasons why your db is performing so slowly. Thirty times slow is too much, and 30s for a query, no matter what query, is wrong. Benchmark your entire stack to find bottlenecks... Is the query itself taking that long? Is something else going wrong? Is the exact query that MapServer is performing actually using your indexes? -- Puneet Kishor From woodbri at swoodbridge.com Sat Apr 28 07:57:29 2012 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Sat, 28 Apr 2012 10:57:29 -0400 Subject: [mapserver-users] Really slow map creation from POSTGIS DB In-Reply-To: References: <4F9BEEAA.7000903@swoodbridge.com> Message-ID: <4F9C0559.6020205@swoodbridge.com> On 4/28/2012 9:44 AM, Puneet Kishor wrote: > On Apr 28, 2012, at 8:20 AM, Stephen > Woodbridge wrote: > >> On 4/28/2012 8:44 AM, Matt McClelland wrote: >>> Hi All >>> >>> I have a set of contours in a SHP file If I point my map file to >>> the SHP file I can generate a WMS image in under 1 second Shp >>> file is just shy of 200MB >>> >>> I then use shp2pgsql to load the same dataset into the DB I added >>> an index for the_geom And am requesting the data in the mapfile >>> using the same EPSG >>> >>> The map draws correclty but is now taking about 30secs when using >>> the DB. >>> >>> Any ideas on how to make it faster. >> >> Simplify the data for the that zoom level. >> >> If you are all the way zoomed out and drawing all the data, then >> the shapefile will be fastest. An index does not help if you are >> drawing all the data as you need to do a full table scan anyway to >> get all the records. It is simply faster to read 200MB from disk >> than from the database because the database has to fetch the same >> data and may have to jump through some hoops to get it out of >> extended storage, then it has to encode the data and send it over >> the connection and the client has to decode the data. >> >> Do you really need all the resolution of the data at this scale? If >> not create another column and simplify the geometry into that >> column and set up your mapfile to query the simplified data at this >> zoom and to query the detailed data as you zoom in. > > > All of the above is great advice. Additionally, implement a tilecache > server; why redraw an image if it has already been drawn. > > That said, while a db is going to be slower than the file system in > many cases, there are many reasons why your db is performing so > slowly. Thirty times slow is too much, and 30s for a query, no matter > what query, is wrong. Benchmark your entire stack to find > bottlenecks... Is the query itself taking that long? Is something > else going wrong? Is the exact query that MapServer is performing > actually using your indexes? In pgAdmin or from the psql commandline, how long does it take to do: select * from yourtable; Do you have the exact query that mapserver is making? You can get it by adding to the MAP object DEBUG 10 CONFIG MS_ERRORFILE "stderr" then looking in the apache error_log. -Steve From jcigar at ulb.ac.be Sat Apr 28 11:22:51 2012 From: jcigar at ulb.ac.be (Julien Cigar) Date: Sat, 28 Apr 2012 20:22:51 +0200 Subject: [mapserver-users] Really slow map creation from POSTGIS DB In-Reply-To: References: Message-ID: <4F9C357B.8030403@ulb.ac.be> On 04/28/2012 14:44, Matt McClelland wrote: > Hi All > > I have a set of contours in a SHP file > If I point my map file to the SHP file I can generate a WMS image in > under 1 second > Shp file is just shy of 200MB > > I then use shp2pgsql to load the same dataset into the DB > I added an index for the_geom > And am requesting the data in the mapfile using the same EPSG > > The map draws correclty but is now taking about 30secs when using the DB. > are you sure your postgresql is well configured ? can you pastebin your postgresql.conf and some details about your configuration ? > Any ideas on how to make it faster. > > Thanks > > Matt :) > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From stwomey at hotmail.com Sat Apr 28 12:15:24 2012 From: stwomey at hotmail.com (Sean Twomey) Date: Sat, 28 Apr 2012 12:15:24 -0700 Subject: [mapserver-users] help - mapserver and postgis connection In-Reply-To: <20120428160016.23497E0111D@lists.osgeo.org> References: <20120428160016.23497E0111D@lists.osgeo.org> Message-ID: I have had success in displaying my layers from a shapefile folder, but can't re-create from the POSTGIS database. I changed my pg_hba.conf file to this... host DATABASE USER CIDR-ADDRESS METHOD host all all 0.0.0.0/0 md5 and this: host all all 142.232.0.1/16 md5 both postgresql.conf file are set to listen to '*' and I have flopped from port 5432 (v. 9.1) to 5433 (v. 8.4), I apparently have both postgresql 8.4 and 9.1 running... I constantly get this: msDrawMap(): Image handling error. Failed to draw layer named 'en_grantedonly_soionly'. msPostGISLayerOpen(): Query error. Database connection failed (could not translate host name "htgProject" to address: Name or service not known ) with connect string 'host=htgProject port=5432 user=stwomey password=*********' Is the database running? Is it allowing connections? Does the specified user exist? Is the password valid? Is the database on the standard port? Ideas? Very challenging!! Sean -------------- next part -------------- An HTML attachment was scrubbed... URL: From stwomey at hotmail.com Sat Apr 28 12:39:23 2012 From: stwomey at hotmail.com (Sean Twomey) Date: Sat, 28 Apr 2012 12:39:23 -0700 Subject: [mapserver-users] help - mapserver and postgis connection In-Reply-To: References: , <1335641619.29475.YahooMailClassic@web160706.mail.bf1.yahoo.com>, Message-ID: Ha! First timer here... I put my database name into the host= part, and didn't even have dbname= now that I do, it works!!! Wow! Fantastic!! Date: Sat, 28 Apr 2012 12:33:39 -0700 From: pcreso at yahoo.com Subject: Re: [mapserver-users] help - mapserver and postgis connection To: stwomey at hotmail.com What happens if you use the IP address instead of the hostname? --- On Sun, 4/29/12, Sean Twomey wrote: From: Sean Twomey Subject: [mapserver-users] help - mapserver and postgis connection To: mapserver-users at lists.osgeo.org Date: Sunday, April 29, 2012, 7:15 AM I have had success in displaying my layers from a shapefile folder, but can't re-create from the POSTGIS database. I changed my pg_hba.conf file to this... host DATABASE USER CIDR-ADDRESS METHOD host all all 0.0.0.0/0 md5 and this: host all all 142.232.0.1/16 md5 both postgresql.conf file are set to listen to '*' and I have flopped from port 5432 (v. 9.1) to 5433 (v. 8.4), I apparently have both postgresql 8.4 and 9.1 running... I constantly get this: msDrawMap(): Image handling error. Failed to draw layer named 'en_grantedonly_soionly'. msPostGISLayerOpen(): Query error. Database connection failed (could not translate host name "htgProject" to address: Name or service not known ) with connect string 'host=htgProject port=5432 user=stwomey password=*********' Is the database running? Is it allowing connections? Does the specified user exist? Is the password valid? Is the database on the standard port? Ideas? Very challenging!! Sean -----Inline Attachment Follows----- _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From arnd.wippermann at web.de Sat Apr 28 15:14:21 2012 From: arnd.wippermann at web.de (Arnd Wippermann) Date: Sun, 29 Apr 2012 00:14:21 +0200 Subject: AW: [mapserver-users] Open Layers Problem In-Reply-To: <000001cd24ed$7d0ac7c0$77205740$@com.mx> References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx><1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com> <000001cd24ed$7d0ac7c0$77205740$@com.mx> Message-ID: <1B6F9996F17E49ECB4B21527E7044FDB@pcawh2> your server http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map works also well with OpenLayers. This should show your server with OpenLayers: http://gis.ibbeck.de/olclient/OLClient.asp?WMC=./data/WMC/BiciMapasMS.wmc.xm l Perhaps you use not the right zoomlevel in OpenLayers to see anything. I have to use zoomlevel 16 to see something. by the way also you have corrected it, the mapfile path have to be a filesystem path and not an url. Arnd _____ Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Samstag, 28. April 2012 05:17 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Brent, Thanks for testing it. The "home/bicimapas/" path is the webserver directory tree. As a fact this same test map works well using the Mapserver templates as you can test with this link http://173.236.45.118/bcmpms_i.html which is the initialization page. Press "Acceder" and you will be taken to the map. The question here is why can the Mapserver template can access the file while OpenLayers does not. Is there a reference document or tutorial on how to properly set up OpenLayers to work with Mapserver? Alberto Najera De: pcreso at pcreso.com [mailto:pcreso at pcreso.com] Enviado el: viernes, 27 de abril de 2012 07:26 p.m. Para: mapserver-users at lists.osgeo.org; Alberto Najera Asunto: RE: [mapserver-users] Open Layers Problem Hi Alberto, I can get the capabilities document, & a list of available layers, using the WMS facility in Quantum GIS, but when I try to access/load the layers as a map the request fails: "Response: MapServer Message msLoadMap(): Unable to access file. (http://173.236.45.118/home/bicimapas/mapdata/BiciMapasMS.map) " I suggest that having your mapfile in your home directory tree rather than your webserver's directory tree might be the problem. You might also try tools like uDIG or QGIS to access the WMS service & debug it before you try to get it working with OpenLayers. Cheers, Brent Wood -------------- next part -------------- An HTML attachment was scrubbed... URL: From anajera at bicimapas.com.mx Sun Apr 29 11:04:01 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Sun, 29 Apr 2012 13:04:01 -0500 Subject: [mapserver-users] Open Layers Problem References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx><1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com> <000001cd24ed$7d0ac7c0$77205740$@com.mx> <1B6F9996F17E49ECB4B21527E7044FDB@pcawh2> Message-ID: <000501cd2632$75d58440$61808cc0$@com.mx> Arnd, Thanks for the test and the link showing one of our test map WMS layers. I good to know it is working now after fixing the map file path. I have been trying to get the map image in OpenLayers but cannot yet make it show. As you, I think that the issue now is that the sample is very small and scale settings shall be used. This is what I have put together but still cannot see it Open Layers Test mapa de prueba
What should be changed? Alberto Najera De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: s?bado, 28 de abril de 2012 05:14 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem your server http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map works also well with OpenLayers. ? This should show your server?with OpenLayers: ? http://gis.ibbeck.de/olclient/OLClient.asp?WMC=./data/WMC/BiciMapasMS.wmc.xm l ? Perhaps you use not the right zoomlevel in OpenLayers to see anything. I have to use zoomlevel 16 to see something. ? by the way also you have corrected it, the mapfile path have to be a filesystem path and not an url. ? Arnd From arnd.wippermann at web.de Sun Apr 29 15:47:58 2012 From: arnd.wippermann at web.de (Arnd Wippermann) Date: Mon, 30 Apr 2012 00:47:58 +0200 Subject: AW: [mapserver-users] Open Layers Problem In-Reply-To: <000501cd2632$75d58440$61808cc0$@com.mx> References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx><1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com><000001cd24ed$7d0ac7c0$77205740$@com.mx><1B6F9996F17E49ECB4B21527E7044FDB@pcawh2> <000501cd2632$75d58440$61808cc0$@com.mx> Message-ID: <0156734553DD4DB38B1112496CF509F9@pcawh2> You have forgotten some commas map = new OpenLayers.Map('map_element', { controls: [ new OpenLayers.Control.Navigation(), //here new OpenLayers.Control.PanZoomBar(), //and her new OpenLayers.Control.LayerSwitcher() ], //and here maxExtent: new OpenLayers.Bounds (-99.269569,19.479910, -99.224060, 19.524080), maxScale: 15000, minScale: 2500 }); Now also not needed anymore // Add a layer switcher control The map and the WMS layer should show now. Arnd -----Urspr?ngliche Nachricht----- Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Sonntag, 29. April 2012 20:04 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Arnd, Thanks for the test and the link showing one of our test map WMS layers. I good to know it is working now after fixing the map file path. I have been trying to get the map image in OpenLayers but cannot yet make it show. As you, I think that the issue now is that the sample is very small and scale settings shall be used. This is what I have put together but still cannot see it Open Layers Test mapa de prueba
What should be changed? Alberto Najera De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: s?bado, 28 de abril de 2012 05:14 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem your server http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map works also well with OpenLayers. ? This should show your server?with OpenLayers: ? http://gis.ibbeck.de/olclient/OLClient.asp?WMC=./data/WMC/BiciMapasMS.wmc.xm l ? Perhaps you use not the right zoomlevel in OpenLayers to see anything. I have to use zoomlevel 16 to see something. ? by the way also you have corrected it, the mapfile path have to be a filesystem path and not an url. ? Arnd _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From Marc-Andre.Morin at dfo-mpo.gc.ca Sun Apr 29 18:10:46 2012 From: Marc-Andre.Morin at dfo-mpo.gc.ca (Marc-Andre Morin) Date: Sun, 29 Apr 2012 18:10:46 -0700 (PDT) Subject: [mapserver-users] Re: Projection issue with vrt file In-Reply-To: <1335542022016-4934316.post@n6.nabble.com> References: <33E3342755CFC844901AD4572AD514A4039E4655@lauqueex01.lau.dfo-mpo.ca> <1335542022016-4934316.post@n6.nabble.com> Message-ID: <1335748246689-4939740.post@n6.nabble.com> One more detail... I used GDAL 1.7.0b2 to get the last warning about the rotated geo transforms unsupported. If I use GDAL version 1.8.1, I get a new warning: Warning 6: gdalbuildvrt does not support ungeoreferenced image. Skipping E:\ms4w \apps\marinfo\data\BSB\KAP\131701.kap Thanks, Marc-Andr? -- View this message in context: http://osgeo-org.1560.n6.nabble.com/Projection-issue-with-vrt-file-tp4903846p4939740.html Sent from the Mapserver - User mailing list archive at Nabble.com. From Jessica.Clarke at forestrytas.com.au Sun Apr 29 22:18:20 2012 From: Jessica.Clarke at forestrytas.com.au (Jessica Clarke) Date: Mon, 30 Apr 2012 15:18:20 +1000 Subject: [mapserver-users] extracting geo data from a tiff Message-ID: <4F9EAD3C020000DD00014708@mail2.forestrytas.com.au> Hi, I'm trying to find out the geographic coordinates of an output map. Please correct me if there is an easier way, but I have added the GDAL/GTIFF output format to my mapfile, and I am calling it with ...&qformat=GTiff&... in my URL so that it selects that instead of the png output format (which is already in use by a large number of people). What I want to do now, is produce a report that gives the top-left coordinate of the map. Is there a way to extract this information and produce a report? My thought process at the moment: Include another outputformat which is text so my URL would be ...&qformat=GTiff+report&... But I'm not sure how to do that exactly, or how to extract the coordinates. I have run GDAL info in cmd, so I'm aware of the data that is contained. Any advice would be appreciated. I am hoping I'm on the right track at the moment. Thanks in advance, Jess --------------------------------------------------------------------------------------------------------------------------------------------- This transmission is intended solely for the person or organisation to whom it is addressed. It is confidential and may contain legally privileged information. If you have received this transmission in error, you may not use, copy or distribute it. Please advise us by return e-mail or by phoning 61 3 6235 8333 and immediately delete the transmission in its entirety. We will meet your reasonable expenses of notifying us. Despite our use of anti-virus software, Forestry Tasmania cannot guarantee that this transmission is virus-free. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aperi2007 at gmail.com Mon Apr 30 04:13:15 2012 From: aperi2007 at gmail.com (Andrea Peri) Date: Mon, 30 Apr 2012 13:13:15 +0200 Subject: [mapserver-users] Layers mutually exclusive Message-ID: Hi, is possible in Map Server to set two or more layers (raster layers) to be mutually exclusive to each other ? I have some raster set each of they is fully cover. So if pretty unuseful to have a wms request that ask for two or more of this layer sets. I don't know if this is possible, but if it could be possible it was surely give a better performance for my MapServer. Infact if an user ask for many raster set, only the top-most should be visible instead the other asked layers in the same request was not visible and they would be only an unuseful lost of elaboration time. Thx, -- ----------------- Andrea Peri . . . . . . . . . qwerty ????? ----------------- -------------- next part -------------- An HTML attachment was scrubbed... URL: From anajera at bicimapas.com.mx Mon Apr 30 09:28:52 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Mon, 30 Apr 2012 11:28:52 -0500 Subject: [mapserver-users] Open Layers Problem In-Reply-To: <0156734553DD4DB38B1112496CF509F9@pcawh2> References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx><1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com><000001cd24ed$7d0ac7c0$77205740$@com.mx><1B6F9996F17E49ECB4B21527E7044FDB@pcawh2> <000501cd2632$75d58440$61808cc0$@com.mx> <0156734553DD4DB38B1112496CF509F9@pcawh2> Message-ID: <001401cd26ee$555ccef0$00166cd0$@com.mx> Thanks Arnd, Added the missing commas, but no map yet (code below). I guess I will have to give a deeper look at how to define a region and zoom level for a map to show in Openlayers. It was very simple with the Mapserver mapfile, and I expected it would be as easy in openlayers. Open Layers Test mapa de prueba
Alberto Najera ? -----Mensaje original----- De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: domingo, 29 de abril de 2012 05:48 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem You have forgotten some commas map = new OpenLayers.Map('map_element', { controls: [ new OpenLayers.Control.Navigation(), //here new OpenLayers.Control.PanZoomBar(), //and her new OpenLayers.Control.LayerSwitcher() ], //and here maxExtent: new OpenLayers.Bounds (-99.269569,19.479910, -99.224060, 19.524080), maxScale: 15000, minScale: 2500 }); Now also not needed anymore // Add a layer switcher control The map and the WMS layer should show now. Arnd -----Urspr?ngliche Nachricht----- Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Sonntag, 29. April 2012 20:04 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Arnd, Thanks for the test and the link showing one of our test map WMS layers. I good to know it is working now after fixing the map file path. I have been trying to get the map image in OpenLayers but cannot yet make it show. As you, I think that the issue now is that the sample is very small and scale settings shall be used. This is what I have put together but still cannot see it Open Layers Test mapa de prueba
What should be changed? Alberto Najera De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: s?bado, 28 de abril de 2012 05:14 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem your server http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map works also well with OpenLayers. ? This should show your server?with OpenLayers: ? http://gis.ibbeck.de/olclient/OLClient.asp?WMC=./data/WMC/BiciMapasMS.wmc.xm l ? Perhaps you use not the right zoomlevel in OpenLayers to see anything. I have to use zoomlevel 16 to see something. ? by the way also you have corrected it, the mapfile path have to be a filesystem path and not an url. ? Arnd _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From arnd.wippermann at web.de Mon Apr 30 10:12:23 2012 From: arnd.wippermann at web.de (Arnd Wippermann) Date: Mon, 30 Apr 2012 19:12:23 +0200 Subject: AW: [mapserver-users] Open Layers Problem In-Reply-To: <001401cd26ee$555ccef0$00166cd0$@com.mx> References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx><1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com><000001cd24ed$7d0ac7c0$77205740$@com.mx><1B6F9996F17E49ECB4B21527E7044FDB@pcawh2><000501cd2632$75d58440$61808cc0$@com.mx><0156734553DD4DB38B1112496CF509F9@pcawh2> <001401cd26ee$555ccef0$00166cd0$@com.mx> Message-ID: Sorry, but i haven't mentioned yesterday, that you have also forgotten an es. use map.addLayers([layer1]); //to add a couple of layers or map.addLayer(layer1); //to add one layer And here add the lost decimal point to latitude: var map_center = new OpenLayers.LonLat(-99.24801,19.49775); Now your map should show your layer. Arnd -----Urspr?ngliche Nachricht----- Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Montag, 30. April 2012 18:29 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Thanks Arnd, Added the missing commas, but no map yet (code below). I guess I will have to give a deeper look at how to define a region and zoom level for a map to show in Openlayers. It was very simple with the Mapserver mapfile, and I expected it would be as easy in openlayers. Open Layers Test mapa de prueba
Alberto Najera ? -----Mensaje original----- De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: domingo, 29 de abril de 2012 05:48 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem You have forgotten some commas map = new OpenLayers.Map('map_element', { controls: [ new OpenLayers.Control.Navigation(), //here new OpenLayers.Control.PanZoomBar(), //and her new OpenLayers.Control.LayerSwitcher() ], //and here maxExtent: new OpenLayers.Bounds (-99.269569,19.479910, -99.224060, 19.524080), maxScale: 15000, minScale: 2500 }); Now also not needed anymore // Add a layer switcher control The map and the WMS layer should show now. Arnd -----Urspr?ngliche Nachricht----- Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Sonntag, 29. April 2012 20:04 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Arnd, Thanks for the test and the link showing one of our test map WMS layers. I good to know it is working now after fixing the map file path. I have been trying to get the map image in OpenLayers but cannot yet make it show. As you, I think that the issue now is that the sample is very small and scale settings shall be used. This is what I have put together but still cannot see it Open Layers Test mapa de prueba
What should be changed? Alberto Najera De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: s?bado, 28 de abril de 2012 05:14 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem your server http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map works also well with OpenLayers. ? This should show your server?with OpenLayers: ? http://gis.ibbeck.de/olclient/OLClient.asp?WMC=./data/WMC/BiciMapasMS.wmc.xm l ? Perhaps you use not the right zoomlevel in OpenLayers to see anything. I have to use zoomlevel 16 to see something. ? by the way also you have corrected it, the mapfile path have to be a filesystem path and not an url. ? Arnd _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From anajera at bicimapas.com.mx Mon Apr 30 10:56:10 2012 From: anajera at bicimapas.com.mx (Alberto Najera) Date: Mon, 30 Apr 2012 12:56:10 -0500 Subject: [mapserver-users] Open Layers Problem In-Reply-To: References: <005d01cd24cd$0a443430$1ecc9c90$@com.mx><1335572771.79820.YahooMailClassic@web160706.mail.bf1.yahoo.com><000001cd24ed$7d0ac7c0$77205740$@com.mx><1B6F9996F17E49ECB4B21527E7044FDB@pcawh2><000501cd2632$75d58440$61808cc0$@com.mx><0156734553DD4DB38B1112496CF509F9@pcawh2> <001401cd26ee$555ccef0$00166cd0$@com.mx> Message-ID: <002d01cd26fa$87e71400$97b53c00$@com.mx> Uff... Those were some very silly mistakes on my side. Thank you, it is working now. I really appreciate your help. Greetings Alberto Najera www.bicimapas.com.mx www.bicimapas.com.mx/Empresa.htm Avenida Lomas Verdes No. 58, Local 17 Colonia Santa Cruz Acatl?n Naucalpan, Estado de M?xico M?xico CP 53150 Tel: (55) 53 60 30 65 anajera at bicimapas.com.mx ? B?scanos como Bicimapas ? -----Mensaje original----- De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: lunes, 30 de abril de 2012 12:12 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem Sorry, but i haven't mentioned yesterday, that you have also forgotten an es. use map.addLayers([layer1]); //to add a couple of layers or map.addLayer(layer1); //to add one layer And here add the lost decimal point to latitude: var map_center = new OpenLayers.LonLat(-99.24801,19.49775); Now your map should show your layer. Arnd -----Urspr?ngliche Nachricht----- Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Montag, 30. April 2012 18:29 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Thanks Arnd, Added the missing commas, but no map yet (code below). I guess I will have to give a deeper look at how to define a region and zoom level for a map to show in Openlayers. It was very simple with the Mapserver mapfile, and I expected it would be as easy in openlayers. Open Layers Test mapa de prueba
Alberto Najera ? -----Mensaje original----- De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: domingo, 29 de abril de 2012 05:48 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem You have forgotten some commas map = new OpenLayers.Map('map_element', { controls: [ new OpenLayers.Control.Navigation(), //here new OpenLayers.Control.PanZoomBar(), //and her new OpenLayers.Control.LayerSwitcher() ], //and here maxExtent: new OpenLayers.Bounds (-99.269569,19.479910, -99.224060, 19.524080), maxScale: 15000, minScale: 2500 }); Now also not needed anymore // Add a layer switcher control The map and the WMS layer should show now. Arnd -----Urspr?ngliche Nachricht----- Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Alberto Najera Gesendet: Sonntag, 29. April 2012 20:04 An: mapserver-users at lists.osgeo.org Betreff: RE: [mapserver-users] Open Layers Problem Arnd, Thanks for the test and the link showing one of our test map WMS layers. I good to know it is working now after fixing the map file path. I have been trying to get the map image in OpenLayers but cannot yet make it show. As you, I think that the issue now is that the sample is very small and scale settings shall be used. This is what I have put together but still cannot see it Open Layers Test mapa de prueba
What should be changed? Alberto Najera De: Arnd Wippermann [mailto:arnd.wippermann at web.de] Enviado el: s?bado, 28 de abril de 2012 05:14 p.m. Para: 'Alberto Najera' CC: mapserver-users at lists.osgeo.org Asunto: AW: [mapserver-users] Open Layers Problem your server http://173.236.45.118/cgi-bin/mapserv?map=/home/bicimapas/mapdata/BiciMapasM S.map works also well with OpenLayers. ? This should show your server?with OpenLayers: ? http://gis.ibbeck.de/olclient/OLClient.asp?WMC=./data/WMC/BiciMapasMS.wmc.xm l ? Perhaps you use not the right zoomlevel in OpenLayers to see anything. I have to use zoomlevel 16 to see something. ? by the way also you have corrected it, the mapfile path have to be a filesystem path and not an url. ? Arnd _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From Steve.Lime at state.mn.us Mon Apr 30 11:13:03 2012 From: Steve.Lime at state.mn.us (Lime, Steve D (DNR)) Date: Mon, 30 Apr 2012 18:13:03 +0000 Subject: [mapserver-users] Layers mutually exclusive In-Reply-To: References: Message-ID: This isn't possible through server configuration that I'm aware of. Sorry... ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] on behalf of Andrea Peri [aperi2007 at gmail.com] Sent: Monday, April 30, 2012 6:13 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Layers mutually exclusive Hi, is possible in Map Server to set two or more layers (raster layers) to be mutually exclusive to each other ? I have some raster set each of they is fully cover. So if pretty unuseful to have a wms request that ask for two or more of this layer sets. I don't know if this is possible, but if it could be possible it was surely give a better performance for my MapServer. Infact if an user ask for many raster set, only the top-most should be visible instead the other asked layers in the same request was not visible and they would be only an unuseful lost of elaboration time. Thx, -- ----------------- Andrea Peri . . . . . . . . . qwerty ????? ----------------- -------------- next part -------------- An HTML attachment was scrubbed... URL: From lists at remoteinformation.com.au Mon Apr 30 17:23:50 2012 From: lists at remoteinformation.com.au (Ben Madin) Date: Tue, 1 May 2012 08:23:50 +0800 Subject: [mapserver-users] extracting geo data from a tiff In-Reply-To: <20120430160013.66912E00ED7@lists.osgeo.org> References: <20120430160013.66912E00ED7@lists.osgeo.org> Message-ID: Jess, This might depend a little bit on what interface you are using to display the map. If you are using templates, you have access to the Map Geometry information, check out : http://mapserver.org/mapfile/template.html#template I think you can access similar information using OpenLayers. If not, do you specify the IMGEXT of your map in your URL? Could you use this information? cheers Ben On 01/05/2012, at 12:00 AM, "Jessica Clarke" wrote: > I'm trying to find out the geographic coordinates of an output map. > Please correct me if there is an easier way, but I have added the GDAL/GTIFF output format to my mapfile, and I am calling it with ...&qformat=GTiff&... in my URL so that it selects that instead of the png output format (which is already in use by a large number of people). > > What I want to do now, is produce a report that gives the top-left coordinate of the map. > Is there a way to extract this information and produce a report? > > My thought process at the moment: > Include another outputformat which is text so my URL would be ...&qformat=GTiff+report&... > But I'm not sure how to do that exactly, or how to extract the coordinates. > > I have run GDAL info in cmd, so I'm aware of the data that is contained. > > Any advice would be appreciated. I am hoping I'm on the right track at the moment. -------------- next part -------------- An HTML attachment was scrubbed... URL: From stwomey at hotmail.com Mon Apr 30 18:42:54 2012 From: stwomey at hotmail.com (Sean Twomey) Date: Mon, 30 Apr 2012 18:42:54 -0700 Subject: [mapserver-users] help -- PostGIS data not displaying as expected, works with shapefiles though! In-Reply-To: <20120430181342.483B0E00E3E@lists.osgeo.org> References: <20120430181342.483B0E00E3E@lists.osgeo.org> Message-ID: Hello, I get the following error when I execute the map file at the bottom of this message: msDrawMap(): Image handling error. Failed to draw layer named 'nationalPark'. msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: Operation on two geometries with different SRIDs I can get this to work when its just a shapefile, but it doesn't work when its coming from PostGIS. I am using Mapserver 6.0.2 with postgresql 9.1 and postgis 1.5.3 Thanks for your help! # Map file created from QGIS project file /htgProject/htgProject_POSTGIS_forMapserver.qgs # Edit this file to customize for your map interface # (Created with PyQgis MapServer Export plugin) MAP NAME "HTG-MAP" # Map image size SIZE 600 600 UNITS meters EXTENT -68586.071680 -336740.884289 1941518.891992 2241795.401077 FONTSET './fonts/fontset.txt' SYMBOLSET './symbols/symbols.txt' SHAPEPATH './data' PROJECTION "init=epsg:3005" END # Background color for the map canvas -- change as desired IMAGECOLOR 255 255 255 IMAGEQUALITY 95 IMAGETYPE png OUTPUTFORMAT NAME png DRIVER 'GD/PNG' MIMETYPE 'image/png' IMAGEMODE PC256 EXTENSION 'png' END # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/tmp/' # WMS server settings #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation TEMPLATE './template/template3.html' END LAYER NAME 'nationalPark' TYPE POLYGON TEMPLATE './template/template3.html' EXTENT -68586.071680 -336740.884289 1941518.891992 2241795.401077 CONNECTIONTYPE postgis CONNECTION "dbname='...' host=... port=5432 user='...' password='...' sslmode=disable" DATA 'the_geom FROM "nationalPark" USING UNIQUE gid USING srid=3005' #DATA 'the_geom FROM nationalPark' #DATA 'nationalPark' METADATA 'ows_title' 'nationalPark' END STATUS default TRANSPARENCY 100 PROJECTION "init=epsg:3005" END # End Projection CLASS NAME 'sea_bc_alb' STYLE WIDTH 0.91 OUTLINECOLOR 0 0 0 COLOR 158 156 14 END END # End Class END # End Layer nationalPark END -------------- next part -------------- An HTML attachment was scrubbed... URL: From punk.kish at gmail.com Mon Apr 30 18:49:55 2012 From: punk.kish at gmail.com (Puneet Kishor) Date: Mon, 30 Apr 2012 20:49:55 -0500 Subject: [mapserver-users] handling features that cross the date line Message-ID: <6F2C4A81-60FB-480B-9715-3F812250E5CC@gmail.com> What is the recommended way of handling such features? I have a bunch of lines (held in Postgis) that cross the date line, and the WMS tiles drawn by MapServer get all messed up. What is the easiest way to get them to draw correctly? Thanks. -- Puneet Kishor From Jessica.Clarke at forestrytas.com.au Mon Apr 30 21:49:01 2012 From: Jessica.Clarke at forestrytas.com.au (Jessica Clarke) Date: Tue, 01 May 2012 14:49:01 +1000 Subject: [mapserver-users] extracting geo data from a tiff In-Reply-To: References: <20120430160013.66912E00ED7@lists.osgeo.org> Message-ID: <4F9FF7DD020000DD0001476C@mail2.forestrytas.com.au> This absolutely fixed my problem. Thanks so much, Ben! Jess >>> Ben Madin 1/05/2012 10:23 AM >>> Jess, This might depend a little bit on what interface you are using to display the map. If you are using templates, you have access to the Map Geometry information, check out : http://mapserver.org/mapfile/template.html#template I think you can access similar information using OpenLayers. If not, do you specify the IMGEXT of your map in your URL? Could you use this information? cheers Ben On 01/05/2012, at 12:00 AM, "Jessica Clarke" wrote: I'm trying to find out the geographic coordinates of an output map. Please correct me if there is an easier way, but I have added the GDAL/GTIFF output format to my mapfile, and I am calling it with ...&qformat=GTiff&... in my URL so that it selects that instead of the png output format (which is already in use by a large number of people). What I want to do now, is produce a report that gives the top-left coordinate of the map. Is there a way to extract this information and produce a report? My thought process at the moment: Include another outputformat which is text so my URL would be ...&qformat=GTiff+report&... But I'm not sure how to do that exactly, or how to extract the coordinates. I have run GDAL info in cmd, so I'm aware of the data that is contained. Any advice would be appreciated. I am hoping I'm on the right track at the moment. --------------------------------------------------------------------------------------------------------------------------------------------- This transmission is intended solely for the person or organisation to whom it is addressed. It is confidential and may contain legally privileged information. If you have received this transmission in error, you may not use, copy or distribute it. Please advise us by return e-mail or by phoning 61 3 6235 8333 and immediately delete the transmission in its entirety. We will meet your reasonable expenses of notifying us. Despite our use of anti-virus software, Forestry Tasmania cannot guarantee that this transmission is virus-free. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lists at remoteinformation.com.au Mon Apr 30 23:04:16 2012 From: lists at remoteinformation.com.au (Ben Madin) Date: Tue, 1 May 2012 14:04:16 +0800 Subject: [mapserver-users] help -- PostGIS data not displaying as expected, works with shapefiles though! In-Reply-To: <20120501045008.2E6FCE00EA7@lists.osgeo.org> References: <20120501045008.2E6FCE00EA7@lists.osgeo.org> Message-ID: <5A7C97EE-8270-4BAB-8D1D-0E8BAA13E617@remoteinformation.com.au> Sean, On 01/05/2012, at 12:50 PM, Sean Twomey wrote: > I get the following error when I execute the map file at the bottom of this message: > > msDrawMap(): Image handling error. Failed to draw layer named 'nationalPark'. msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: Operation on two geometries with different SRIDs > > I can get this to work when its just a shapefile, but it doesn't work when its coming from PostGIS. I am using Mapserver 6.0.2 with postgresql 9.1 and postgis 1.5.3 It sounds like maybe your shape file has been imported with a different geometry to that which you are telling it in your request: DATA 'the_geom FROM "nationalPark" USING UNIQUE gid USING srid=3005' would suggest that the data is in the database in the EPSG:3005 (British Columbia Albers) projection. Check that it is ?? cheers Ben