[Django]-Trying to build simple web app with Google Maps API

5👍

Here are a few useful links if you decide to go for Rails:

👤Mischa

1👍

What you are trying to do doesn’t have much to do with Django or Rails. It will be mostly javascript. Here’s a simple implementation outline:

  1. Follow the tutorials to get started on google maps api on a static local html file.
  2. In javascript write a map_init and add_marker helper functions.
  3. When confident, add the link, div, and script tags you wrote to your template.
  4. Have your view/controller method get a list of objects from the db.
  5. Pass them to the template
  6. In the template do a for loop over the object list.
    • inside the loop use the appropriate obj attributes to feed the add_marker helper function.

Leave a comment