Tag Info

Hot answers tagged

4

In order to install the MapServer in Ubuntu 14.04 after you have installed Apache2, it is good to install php5: sudo apt-get install php5 After that you can install the available in the repositories version of the MapServer by executing: sudo apt-get install cgi-mapserver mapserver-bin php5-mapscript However, the available version in the Ubuntu ...


4

Step-by-step for GeoServer. Note: As @michal-mackiewicz writes, the WPS extension for GeoServer must be installed. Acquire some point data, for example Natural Earth populated places http://www.naturalearthdata.com/http//www.naturalearthdata.com/download/10m/cultural/ne_10m_populated_places.zip Import data into Postgis for example with ogr2ogr ogr2ogr ...


4

For example: let's say you have a 10 megabyte raster/vector file that covers a large area. If you include the file directly into OpenLayers, it will download the entire file to the browser and render whatever part of it the map needs even if it's a small area. What mapserver will do for you is always deliver to the browser a small image of exactly what ...


4

EDIT: Update, having belatedly realized this is a Map Server question. In general, to get the convex hull, you will want to group by id/gid, as producing the hull(s) is an aggregate operation. So, without the Mapserver part, the query would look like: SELECT id, ST_ConvexHull(ST_Collect(the_geom)) as the_geom from xyz group by id; Now, to get MapServer ...


4

There are two mode in MapServer in fact and it can be confusing for end users without knowledge about the project history. The first one, the now mostly outdated mode cgi (the url contains mode=browse) way where you don't rely on standards OGC webservices. It was supported in OpenLayers 2 by default because of history (more Mapserver instances not using ...


3

The loader should be defined with the callback function that is called when the response has been completely loaded. One way of doing this: loader: function(extent, resolution, projection) { var url = ...


3

How about using GDAL_Grid? Just pass the arguments over to GDAL and return the raster file or render it in the web browser. It does IDW, Nearest neighbor, and averaging and has a robust set of input parameters.


2

Thinking that you need heat maps rendered on the fly, I would go for these options instead: Leaflet: http://www.patrick-wied.at/static/heatmapjs/example-heatmap-leaflet.html OpenLayers: http://www.websitedev.de/temp/openlayers-heatmap-layer.html Both LL and OL: http://www.patrick-wied.at/static/heatmapjs/examples.html Some on-the-fly examples: ...


2

With MapServer the pixel value of a raster layer that should be interpreted as "nodata" and which should therefore be transparent is defined in the LAYER section of mapfile with the OFFSITE parameter. This is explained in MapServer documention at http://mapserver.org/mapfile/layer.html?highlight=offsite%20raster.


2

Turns out it is as easy as this: MIMETYPE "application/json; subtype=geojson; charset=utf-8" Without the setting, no content encoding is returned by the server.


2

I just ran into this issue and found that the problem was because I had not installed the ‘proj-epsg’ package. yum install proj-epsg


2

Kaarel´s answer should be marked as the correct answer. You need to call the loadFeatures function from the AJAX call. I created three jsfiddle to demonstrate ol 3.5.0 calls via AJAX for ol.format.GeoJSON (JSON and JSONP) as well as ol.format.WFS. WFS http://jsfiddle.net/goldrydigital/9d3jzpna/ JSON http://jsfiddle.net/goldrydigital/ucspgvx0/ JSONP ...


2

Just see this official demo example http://openlayers.org/en/v3.0.0/examples/wms-image.html Some others WMS samples are available. You will just need to change ServerType to mapserver (link for reference) Edit for completing with solution Without proj4js, you can always use the recipe from this other official example Declare an object ol.proj.Projection ...


2

With the fixed mapfile, it become clear to me, this is a client side problem. There is nothing wrong with the MapServer setup, the resolution limit has been set in the OpenLayers map object automatically. To override this limit, include a maxResolution parameter in your OpenLayers.Map constructor. var map = new OpenLayers.Map('map', { ...


2

It is not possible with version 5.6.8 but if you update to version 6.4 you can use the SIA shape smoothing algorithm. The RFC of the feature is in http://mapserver.org/development/rfc/ms-rfc-94.html and current documentation about the usage in http://mapserver.org/output/shape_smoothing.html#shape-smoothing. If you must to stay with the old 5.6.8 the only ...


2

I'd start with GeoServer on the server side. You just need to put the files on the hard drive, create an ImageMosaic store, then publish whatever layers (perhaps just one) you need. The ImageMosaic is the critical part - that will turn your collection of aerial photographs into a single image. Note that there are likely to be some artifacts where the images ...


2

We work regularly with tiled layers in our applications and I usually store tiles directly on a dedicated disk which I host as a virtual directory. You can see the tile directory here: http://argeomatica2012.cloudapp.net/SOLIDARIDAD_ortho/ I then add the tiles directly as a XYZ layer to my OpenLayers map like so: layerXYZ = new OpenLayers.Layer.XYZ("XYZ ...


2

Looks like there's no current indent implementation for map files so you'll most likely have to write your own. However, if you're not already aware mapserver.org provides both syntax coloring and folding vim plugins. The files were written a while ago, so you may need to tweak it or find a newer one. To install: mkdir ~/.vim/syntax/ cd ~/.vim/syntax ...


1

I found the solution, it basically was to change this: -DCMAKE_LEGACY_CYGWIN_WIN32=1 to -DCMAKE_LEGACY_CYGWIN_WIN32=0 so, I used: cmake .. -DWITH_OGR=0 -DWITH_GDAL=0 -DWITH_WCS=0 -DWITH_WFS=0 -DCMAKE_LEGACY_CYGWIN_WIN32=0 and Mapserver compiled flawlessly.


1

If security is not an issue but you only want to load data within the current viewport. You can also look at OpenLayers BBOX strategy.


1

To investigate an error in a script file with psql, it may help to identify the first error by stopping the script on the first error with: \set ON_ERROR_STOP on This is off by default, which is why you might see repeated noise messages "ERROR: current transaction is aborted, commands ignored until end of transaction block" With an error like: ...


1

Expressions in MapServer are rather messy from users point of view even the documentation at http://www.mapserver.org/mapfile/expressions.html may feel fine for MapServer developers. What user must know is that datatypes matter and syntax is different for numbers and strings. For strings both the attribute name and its value must be quoted EXPRESSION ...


1

From a clean Ubuntu 12.04 Precise install I was able to get it to work with this: echo 'deb http://ppa.launchpad.net/ubuntugis/ppa/ubuntu precise main' | sudo tee -a /etc/apt/sources.list echo 'deb-src http://ppa.launchpad.net/ubuntugis/ppa/ubuntu precise main' | sudo tee -a /etc/apt/sources.list sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys ...


1

I think this sample should put you on the right track. https://developers.arcgis.com/javascript/jssamples/widget_print_esri_request.html It shows you how to print the map at various scales and it uses the PrintTemplate "format" option. In the sample, they are using PDF but you have other options (pdf | png32 | png8 | jpg | gif | eps | svg | svgz). See the ...


1

Geoserver can render a heatmap from vector points using Rendering Transformations. For this feature to work, you will have to install WPS Extension (but WPS service doesn't need to be enabled).


1

for ubuntu users : open software center and search "python-mapscript" and install "python library for MapServer" and enjoy using "RT mapserver exporter".


1

Found one on GitHub : MapserverSyntaxHighlighting It adds a user defined language in N++ (check this, if you want to create your own). Just put the two files given here : userDefineLang.xml -> %appdata%\Notepad++ mapfile.xml -> %programfiles(x86)%\Notepad++\plugins\APIs You may need to restart N++ or reopen the mapfile.


1

QGIS Server has some limitations but you can add Lizmap on top and get more functionalities. The documentation is pretty good but it lacks a good English translation from french. It handles users/groups. Cache management Bing, Google, IGN, OSM base layers You can easily build html popup for getFeatureInfo calls. The Lizmap plugin is very handy and gives ...


1

As noted in a comment by neuhausr there is a documented solution for this problem on the GDAL site GDAL info page for ESRI Personal GeoDatabase, but the solution is only for Linux. If like me you find yourself on a 64-bit Windows platform and have 64-bit MapServer/GDAL you might find yourself scratching your head, as yes you can get the same error :-( ...


1

It's been a long time since I last compiled MapServer, but usually all you had to do was: ./configure ./make ./make install 'configure' basically evaluates what libraries are installed on your machine and creates a 'make file'. 'Make' then compiles the mapserv executable. To serve shapefiles and tifs I think you need the gdal library, so you may have to ...



Only top voted, non community-wiki answers of a minimum length are eligible