Bouwen van MapServer
Onder Ubuntu valt MapServer via de volgende stappen te bouwen. Netbeans kan als IDE gebruikt worden hierbij.
De source code wordt in de huidige folder uitgepakt door:
$ apt-get source cgi-mapserver
De voor bouwen benodigde pakketten worden geïnstalleerd door:
$ sudo apt-get build-dep cgi-mapserver
Bij mij werden hierbij zo'n 99 pakketten opgehaald, maar het aantal hangt natuurlijk af van wat er op het systeem aanwezig is.
NO_PUBKEY F9A2F76A9D1A0061
When apt-get returns an error message like NO_PUBKEY F9A2F76A9D1A0061, the problem can be solved by adding a valid key:
$ gpg --keyserver keyserver.ubuntu.com --recv F9A2F76A9D1A0061
$ gpg --export --armor F9A2F76A9D1A0061 | sudo apt-key add -
In case of a missing key from Opera:
wget -O - http://deb.opera.com/archive.key | sudo apt-key add -
HTML5 support of browsers
HTML5 support of browsers can be tested at http://html5test.com. This test score is only an indication of how well your browser supports the upcoming HTML5 standard and related specifications. It does not try to test all of the new features offered by HTML5.
| Opera 10.62 | Firefox 4.0b6 | Chrome 6.0.472.63 | Safari 5.0.2 | IE8 | IE9 | |
| Total (out of 300) |
159 (+7) Note: 179 for opera-11.00-1029 |
204 (+9) |
MySQL and UTF-8
Having just installed MySQL under Ubuntu 10.04 on an old laptop, I noticed that the default character sets were still latin1. Since utf8 is to be preferred, the easiest way to get this is to add a small utf8.cnf file to the /etc/mysql/conf.d folder.
The file should contain something like;
[mysqld] character-set-server=utf8 default-collation=utf8_unicode_ci [client] default-character-set=utf8
After restarting MySQL you should be ok. Advantage of this approach is that your modified settings are not affected on updates of MySQL.
Mapping kit
This blog will discuss the Mapping kit modules for Drupal and how these interact with e.g. OpenLayers, Mapserver and PHP/Mapscript, shapefiles, PostgreSQL and PostGIS, etc.
WFS layer with timeline
A map can be integrated with the simile timeline control since version 6.x-1.5 of the mapping kit. The date fields of a WFS layer can be displayed as events on the timeline. The bands of the timeline are configurable.
But a good example dataset is still missing ...
[map baselayers="osm" controls="timeline" timeline="height=150,bands={day:50,week:30,year:20},firstband={numUnits:7}" /]
For the bands, you can choose interval units like: "MILLISECOND", "SECOND", "MINUTE", "HOUR", "DAY", "WEEK", "MONTH", "YEAR", "DECADE", "CENTURY", "MILLENNIUM", "EPOCH", and "ERA". The number following the interval unit represents the percentage of the total height.
WFS layer with unique values renderer
The following map shows a WFS layer as in the example at http://openlayers.org/dev/examples/wfs-reprojection.html. When you want to define a unique values renderer for a WFS layer, you need to define 3 extra parameters: styleMap, uniqueValueProperty, and uniqueValueFillColor. This renderer is available in the mapping kit since version 6.x-1.5.
[map zoom="4" controls="default,statusbar,layerswitcher" baselayers="osm" layers="1" 1="wfs|http://sigma.openplans.org/geoserver/ows|States|topp:states|extract=true,styleMap={strokeColor:black,strokeWidth:2,strokeOpacity:0.5,fillOpacity:0.5},uniqueValueProperty=STATE_FIPS,uniqueValueFillColor={01:red,02:green,03:blue,04:brown,05:grey,06:yellow,07:magenta}" center="-103,41" /]
Note that only a few (Southern) states are rendered with this limited definition.
FOSS4G 2008
A look at the Cape Town International Convention Centre where the FOSS4G was held from 29 September to 3 October 2008.
World demo
- Bounding box
- -180,-90,180,90
Demo map file for using world geodata. The layers have been added by automatic classification (equal interval or quantile) of given fields in the geodata.
World countries (pg)
The same world countries data, but imported into PostGIS.
