Solved

How do I place 200 locations on a map through Django

Posted on 2015-01-21
2
85 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

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

What is Node.js? Node.js is a server side scripting language much like PHP or ASP but is used to implement the complete package of HTTP webserver and application framework. The difference is that Node.js’s execution engine is asynchronous and event…
These days, all we hear about hacktivists took down so and so websites and retrieved thousands of user’s data. One of the techniques to get unauthorized access to database is by performing SQL injection. This article is quite lengthy which gives bas…
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 …
Use Wufoo, an online form creation tool, to make powerful forms. Learn how to selectively show certain fields based on user input using rules to gather relevant information and data from your forms. The rules feature provides you with an opportunity…

813 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

10 Experts available now in Live!

Get 1:1 Help Now