
Online Users Map with OpenStreetMap
I’ve finally had a bit of time to work on the online users map block I wrote a while ago – the recent release of Moodle 2 being a bit of a spur. Two main changes I’ve made:
Firstly, I added the option to use either Google Maps or OpenStreetMap, with the default being OpenStreetMap, but you can easily change it in the block settings.
Secondly, I managed to get the block up and running in Moodle 2 (see it in action). It needed a few changes over the previous version to get it to work. I’m still having a few issues with getting the block to update the cron field in the mdl_blocks table – so currently you need to update the blocks table manually to enable the cron function, which automatically updates the user locations.
Any feedback welcome
June 13, 2009, 5:28 pm by Alex
|
Comment
After a long time of not doing much (ok, any) development on my Moodle online users map block, I’ve finally had chance to return to the code to make the necessary changes for the block to run on Moodle 2.
It was always going to be tricky trying to maintain this block whilst in Ethiopia, not only with the slow internet connection, but the university firewall blocks many ports and this is my normal internet access point. So now that I’m temporarily back in the UK, I thought I’ve got chance to get back up to speed.
In the end only minor changes were needed to get the block running on Moodle 2. If you’re downloading the block from the Moodle modules & plugins pages, then please check you get the right one (v1.9 and earlier or v2) for your Moodle installation.
If you’re getting the code via CVS then HEAD currently contains the version for v2 and the MOODLE_19_STABLE branch has the version for 1.9 and earlier.
I’ve also set up a demonstration Moodle site so you can see the block in action. Just sign up, and you should see yourself marked on the Google map. You may have to wait until the location lookup script has run before you appear on the map, but this should only be a few minutes.
Please let me know if you have any problems with either getting the block to run on Moodle 2 or with the demonstration site.