Search

Map Location Field v3 updated to version 3.1.1 on 7th of February 2011

It is possible to have multiple marker ?

Right now, no. But it has been suggested in the past. What do you need it for?

Based on the User Input query (query can be the for eg "church in France"), i have to display the location in the google map with multiple marker that matches the user input query

Shouldn't every location (in your example each church) have its own entry?

I can see a need for multiple markers when you want to mark a series of data points. Perhaps you have a section "Facilities" and one entry is "Public Toilets" and you want to drop a marker onto each public toilet in your area. It doesn't make sense for create a sub-section just for the map (lat/lon) for each toilet, unless you want to store a whole load of meta data about the toilet too (male/female, opening hours etc).

I don't think it would be too difficult to add multiple markers to the UI. Each would need to be removable (right-click, like on Google?) and the database would need to change slightly.

query can be the for eg "church in France"

Are you suggesting you'd need to search Google Maps and then store all of these points? I'd question why you'd need this in the backend, if the results are being served from Google.

i have a section called - departments,fields-> dept name, dept address,dept map, for the map field i used the extension if the user want to search the department from the front end i have to show a single map with multiple marker for the department locations , i want to achieve this how to do this ?

Take a look at the field README, which hints at creating this sort of functionality. I've written an article Building a store locator using the Map Location Field which is a good starting point (although the tutorial site is broken at the moment, I'll inquire...)

Thanks nickdunn! i read the tutorial great tutorial ! it just display the data , i want that data to be marked in the map any idea how to achieve this ? (readme file gave many hints), but still i dont know how to start with :(

The tutorial and this field won't build the map for you on the frontend. For that you'll need to jump into the Google Maps API and get your hands dirty with JavaScript. There are dozens of tutorials about building with Google Maps.

http://code.google.com/apis/maps/documentation/javascript/v2/examples/marker-simple.html

You could always use this nifty Google Maps API for jQuery, developed by, erm, well me!

It's still in early beta, but does multiple markers ok (I hope) if you get stuck with it, drop me an issue on github.

</end-flagrant-self-promotion>

Map Location Field v3 updated to version 3.2.1 on 31st of May 2011

  • no longer requires Google Maps key (now using API v3)
  • CSS fix

@designermokey

You could always use this nifty Google Maps API for jQuery, developed by, erm, well me!

Cool stuff. Senc iuuuuu !

Btw, the link is https://github.com/designermonkey/Goomaps

Yeah, I changed the project when I did a full rewrite, there's so much to do and so little time...

Is it possible to send the address to the field this creates through the front end? I tried this and it didn't work, trying to think how else to access that:

<input name="fields[location][address]" id="fields-location" type="input" />

If so, will it actually geocode the location saving from the front-end? Or would it not fire the right things for that to happen?

Yep should work, I remember patching this field to make it so. Try just fields[location].

It accepts either a single string (an address to geocode, or a latitude,longitude pair):

fields[your-field-name]

e.g.

fields[your-field-name] = Street, Town, Region, Postcode

or

fields[your-field-name] = 10.545,-103.1

Or the raw map settings as an array:

fields[your-field-name][latitude]
fields[your-field-name][longitude]
fields[your-field-name][centre]
fields[your-field-name][zoom]

Has anyone else experienced problems when filtering?

I have a data source that filters via the Map Location Field using, within 15 miles of {$url-origin}. The URL looks like this, http://mywebsite.com/search/?origin=Boston%2C+MA&search=1.

I have three entries that should show every time based on the above URL. However, when I test the URL the first time after having not done any testing for while I get a blank result. If I simply refresh that page, or search again using the same URL I get the three entries I expect.

Interestingly, I have an Ajax page that uses the same data source so that I can create the visual map interface on the same page and it always produces the three results. So, I end up with blank listings but a map showing listings on the same page. This would make me think I'm doing the filter right.

Is there any caching that could be affecting results?

Looking at the code, I think it's a caching problem but I just don't know the inner workings well enough.

Found the problem. I'll submit a pull soon.

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details