User Manual

Style a Map

Styling a Mapzania map can be done in two ways:

Server-Side Styling

Creating server-side maps and then styling them provides a repository of pre-configured maps that can be used in your project.

To add server-side maps, use the Mapzania Map Styler. This can be accessed using the url http://[your site]/mz/styler/html. The maps that are styled using this method are stored in the Mapzania.config file that is located in the root of the .NET project.

These maps can be activated in client-side JavaScript using their assigned keys. This is shown below for a map with the key of 'LONDON':

window.onload = function () {
    var map = new Mapzania.Map("map-div","LONDON");
Client-Side Styling

Client-side map styling is done through JavaScript and can be used to re-style existing layers that have been styled server-side (as above) or to style layers that have been added on the fly.

The Mapzania Javascript Library Documentation is a reference guide with all the styling functions that can be performed client-side.

There a a number of examples that show how client-side styling works in the Javascript Examples section of this site.