0

On my website i'm using the PHP SDK to make api calls. And with it I am able to create an event and edit it afterwards. But what I am not able to do is to set the latitude and longitude of the event.

I've searched for some similar questions, which helped me to set some of the venue fields, like street and city. Something to note is that it seems like Facebook is checking if a city exist. When I had "Antwerpen" as city value, it didn't saved it. But when I used "Antwerp" as city value it added the city, state and country fields of venue.

When I choose a location for an event on the facebook website, and I inspect the event in the Graph API explorer I do see the latitude and longitude values. They are also colored red. Does this mean facebook doesn't allow you to set latitude and longitude settings yourself?

Long story short, I got some events with a name, start_date, end_date and geolocations. And I want to push them to Facebook Events, but I get stuck trying to set the latitude and longitude.. Can somebody help me out?

Kara
  • 6,115
  • 16
  • 50
  • 57

2 Answers2

2

With the current implementation of the API, you cannot set long/lat for events. I know there's others out there that would like this ability. My suggestion to you is to log a bug at http://developers.facebook.com/bugs and see if they will prioritize your idea as a wishlist item. Once you do, then post the link to it here, and I'm sure you will get a few people to subscribe to it, raising awareness with Facebook that more than one of us would like to have this ability.


EDIT

from: Create event with a venue with Graph API

There's a (currently undocumented) parameter which will mark a created event as taking place at a particular Place - When creating the event add the location_id parameter and set it to the ID of the Facebook Place you want.

However, your place id must exist. But still I think you should be able to do lat/long of a location without a place id

DMCS
  • 31,720
  • 14
  • 71
  • 104
  • Thanks for the advice.. I found it actually already been placed as a bug so let's subsribe to it here: https://developers.facebook.com/bugs/173095916131752 – Sammy Hubner Feb 03 '12 at 12:58
0

i was just looking into this too, i thought about doing it with Google Maps Geocoder

in the location field of a facebook event sometimes you will have an address (depends on the creator of course.. ), when i tried to copy and paste it into GoogleMaps search it would sometimes find a location, and sometimes not, this way you can get some of the locations of the events.

i haven't tried this yet in code though..

Dan Levin
  • 718
  • 7
  • 16