Solved

How do I place 200 locations on a map through Django

Posted on 2015-01-21
2
83 Views
Last Modified: 2015-03-23
Hi
I have a table of about 200 locations, with zip/postcodes which I would like to place on a (google) map on my responsive website.

I then want users to be able to choose one (eventually the app will filter based on current location) and get directions to that place from their current location on their phone.

What is the best approach to tackle this? I have found the HTML 5 mapping API but am not sure how to approach.

Do I have to load all the facilities into an array each time a user visits the site? Or is there a better way? I am working within a django framework if that helps?

thanks for your help
0
Comment
Question by:lz7cjc
2 Comments
 
LVL 35

Accepted Solution

by:
Kimputer earned 500 total points
ID: 40564050
Here's how I did it (in PHP/MySQL though).
First get it to generate 1 marker.
Next, get it to generate a marker from file or database.
Then get it to generate all markers from file or database
Fix marker setup (looks, info, links etc)
The link will be important to get directions (not sure for Apple, but Android it will definitely open nicely in Maps (with Navigation only one click away))
Then get it to show markers based on filters.

Loading all 200 markers won't slow it down, as it's all done by Google (while displayed on your site, the Google Maps API handles all the calls, your time loading 200 markers data is negligible).
0
 

Author Comment

by:lz7cjc
ID: 40572798
thanks - however I need to understand how to build a page using a mix of python and javascript as set out in the original question. I understand the process at a conceptual level but not how to execute.

Any ideas?
thanks
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Foolproof security solutions has become one of the key necessities of every e-commerce or Internet banking website. If you too own an online shopping site then its vital for you to equip your web portal with customer security features that can allow…
This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Learn the basics of if, else, and elif statements in Python 2.7. Use "if" statements to test a specified condition.: The structure of an if statement is as follows: (CODE) Use "else" statements to allow the execution of an alternative, if the …
Learn how to set-up PayPal payment integration in your Wufoo form. Allow your users to remit payment through PayPal upon completion of your online form. This is helpful for collecting membership payments, customer payments, donations, and more.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now