English 中文(简体)
“Facebook”活动出现在谷歌地图上。
原标题:Facebook Events appear on Google Map

我能否在“Facebook”标准活动上做一些事情?

Any tips would be much appreciated.

问题回答

Given you have the user_events permission, you can access the locations like so:

FB.api("/me/events", function(events) {
    if(events.error) 
         console.error(events);

    var map = "http://maps.googleapis.com/maps/api/staticmap?zoom=14&size=512x512&maptype=roadmap&sensor=false";

    for(var i = 0; i < events.data.length; i++) {
        var point = "&markers=color:blue%7Clabel:S%7C";
        point += (events.data[i].venue.latitude + "," + events.data[i].venue.longitude);
        map   += point;
    }

    var img = document.createElement("IMG");
    img.src = map;
    document.body.appendChild(img);
});

我对它进行了试验,但这应当足以说明如何在浏览器中接触APIC,并提供地图。 正在使用谷歌地图静态的APIC。

I just created a python script, source here.

它询问了该笔记本,并播放了事件,并将数据列入MySQL表格。 该网站还设有一个Geo-cache图书馆,该图书馆将一个当地数据库与谷歌地图地理编码第二版连接起来,因此,你可以非常快地询问活动的长期和纬度。





相关问题
Mysql trigger/events vs Cronjob

I have an auction website which let my users place an unlimited amount of autobiddings. To monitor these autobiddings something has to check the database every second. My question is if it is ...

Can an event be used as an event listener?

I m trying to expose some events from a private object which is contained inside the object I am creating and it looks like the compiler is happy with this: private WindowUpdateServer ...

鸡奸

由于将javascript DOM方法放在第html页底部(在<有人>之后)远比利用“j Query”准备活动要快得多,因此我们不得不这样做:

Attaching a property to an event in Flex/AS3

I have a parameter that needs to be passed along with an event. After unsuccessful attempts to place it on the type by extending the class, I ve been advised in another SO question to write a custom ...

jQuery bind on ajax load() event

I have a page which displays multiple blocks with results details. Inside each block I have some <a> tags with thickbox jQuery plugin attached: class="thickbox" Here is an example of one kind ...

HTML text input event

I have a form, and want to disable/enable its submit button depending on whether the form s input text fields are empty or have had text entered into them. I think this means having an event handler ...

IE doesn t run Javascript when you click back button

I ve built a shop with tons of JS running. One of the pieces of the cart, is a zip code field which is required to calculate shipping cost. This works fine going through the cart. Now clicking ...

热门标签