Adding layers to the map


Hey guys,

Does anyone know how can I add other layers to the base map in Ushahidi? There is a selector on the top-right corner, and that lets you select layers and groups of locations, but there's currently only one option.

I would like to add other categories, or work with some polygons to be displayed/hidden on the map.

If you have any advice/tip/directions, I would appreciate it.




Hey Pablo,

We've got a build on this next Goma release to address just that. It'll allow you to add a KML or GeoRSS feed and then overlay that on top of your regular data. It'll be rudimentary at first, but it's a start.


It doesn't seem to be there (looking at now), are we talking about the same thing? It will be great to have some layers/overlays for each shared instance of Ushahidi, or even add other map-based data, like polygons.




Looking at OpenLayers now, if anyone is experience in OpenLayers, and want to do some consulting work, get in touch with me!



I do not understand: does ushahidi allow the upload of kml files?




Not yet for what I can see. It is in the pipeline. Still, you can work with OpenLayers to add your own layers to the main map. That's one of the things I'm trying to crack now.



great! I am convinced that such a tool could be extremely useful if it could show information such as risk maps, so to better analyse the area to be monitored.


The OpenLayers code for the front page is in


(or main_js.php is clusering is turned off)

So any Javascript you like can be added there. For instance, you could add something like this after the existing map.addLayer call

var newl = new OpenLayers.Layer.GeoRSS( 'GeoRSS', 'georss.xml');


You'll have to add a proxyHost ( if the GeoRSS or KML file lives on another server.

A bit more detail on


I installed Ushahidi and in the admin panel I found out that I can upload kml or kmz files.

I did, but it seems it does not work.

Could you please give me some help?


How? More details will help.

After uploading the KML or KMZ file, there should be other layers added to the frontend.


I'm having a similar problem with loading KML files.

The loading seems to go fine with no error messages, but I do not find the uploaded layer either on the home page (under category filters) or on the admin panel (under layers). What might be going wrong ?

Related to this issue, what is the appropriate value for Layer URL (when I'm uploading a file) ?




Seems like the viable option is to go muck around with main_cluster_js.php to get layers working.

If this feature is supposed to work without any tweaks, please holler what we might be doing wrong.


I have been using the preinstalled ushahidi via crowdmap, and this still seems to be a problem. I tried to change 'cluster points' in settings, and changed my kml from a url to an uploaded file, but it didn't help.

We did get this working on a previous map with kml we created and exported from google earth. There seems to be some good kml files out there that have (WAY) more data than the map needs. It might be good to build a tool into ushahidi to help address this as well.


This is working for me now if anyone is interested.  I’m not sure if the URL method worked…ok just tested…it does :smiley:  2.6.1


cgchoffman - i’m curious on what worked for you

and for everyone interested in layers - in particular i want the layer to show up when people Submit Reports.

my goal is to use my deployment -

and i want to have layer for a proposed Tar Sands pipeline on the map so folks can post their questions, videos, protests to the project - but they need to see it both on the main page - and on the Submit page since their Reports will be in-relation to the pipeline itself. i’ve got a KML file for the pipeline. this layer shows up fine on the main page once selected. (hidden right now)

is it possible to do what i’m trying to do? i’m working in version 2.4 now but upgrading to 2.6 in the coming days.



HI Paul, I’ve pinged the developer team to take a look at your request.

I think that it would be highly custom to add this to the submit report page.


Hi Paul,

The feature described above would probably require some customisation to be built into the ushahidi platform at the moment. We are moving towards work on version 3.0 of the platform, and have a feature freeze in effect. However, we do welcome members of the community to send in pull requests as we get closer to releasing v3.x.

Have a look at some of the work and items fronted for v3