walling / osrm-rails

Rails front end to the OSRM router

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

About OSRM-Rails

This is a Rails 3 front end for the OSRM routing engine: github.com/DennisOSRM/Project-OSRM

The app uses OpenLayers to displays OpenStreetMap maps, communicates with an OSRM routing server and display routes and instructions to the user. The user can place and move start/end/via markers, etc.

The app is a port of the HTML/Javascript front end by Dennis Schiefer ( github.com/DennisSchiefer/Project-OSRM-Web), but has been modified in a few ways:

  • Use the Rails assets pipeline to server javascript, images and stylesheets.

  • Javascript files has been converted to Coffeescript

  • Uses jQuery for DOM access and manipulation.

  • Uses Eco templates for rendering routing instructions.

  • Internationalization is handled by the build-in Rails libs. Strings are located in config/locales/, and made available to the client-side javascript by the i18n-js gem.

The app is setup to use the OSRM routing demo server at router.project-osrm.org, but you can change this (and other things) be editing the file app/assets/javascript(OSRM.config.js.coffee.

Note: The app has only been tested on Firefox and Safari on Mac. IE fixes are probably required.

Emil Tin

About

Rails front end to the OSRM router