【问题标题】:fusion-tables input into calendar融合表输入到日历中
【发布时间】:2012-08-01 21:32:33
【问题描述】:

我有一个包含我的客户数据库的融合表。一栏是安装日期。我希望能够在谷歌日历中查看该信息。有没有人有一个简单的方法来实现它? 谢谢!

【问题讨论】:

    标签: google-fusion-tables


    【解决方案1】:

    我不认为这个功能已经存在,但自己做这个并不难。

    您可以将one of the client libraries 用于融合表(例如Google APIs Client Library for PHP),然后只需连接到您的融合表,获取您的数据和generate an iCal file。然后,您可以将生成的文件导入 Google 日历,或者将您的脚本放在网络服务器上,然后在 Google 日历中订阅您生成的日历。

    我很快在 PHP 中 put together such a script(网址:http://gft.rdmr.ch/examples/php/GFTCalendar.php),也许你可以从它开始,或者只是使用你最喜欢的编程语言来自己做。

    【讨论】:

    • 我需要更多指导 - 提前感谢您的耐心等待。我是第一个计时器!我将 API 库与您的示例代码一起上传到了我的服务器。需要一些帮助来理解我从这里做什么。谢谢!
    • 事实上,如果您有时间为我服务,我愿意为您的服务付费!
    • 我认为没有必要。你想知道什么?我认为整个 iCal 部分并不是很困难(取决于您要使用多少“日历”功能,但对于简单的一日约会,我的脚本将起作用)。困难的部分是从您的融合表中获取数据。它是公共桌子还是私人桌子?对于私有表,您必须有某种登录(ClientLogin 或首选 OAuth)。完成设置后,剩下的就是编写返回所需数据的 SQL 语句。
    • 对不起 - 我想我是在我的头上。你知道有谁愿意为我做这件事,只收取象征性的费用吗?如果我能找到任何人,我还有一些融合项目很想帮忙。
    【解决方案2】:

    因为它看起来是一个很酷的挑战,所以我在这里完成了它:

    https://github.com/fontanon/google-fusiontables2calendar

    它提供了一个配置文件,方便大家进行设置:

    <?php 
    
    // ::auth config::
    // Google Public API Access Key. Don't forget to activate Google API for fusion tables
    // Get one and configure access and perms at https://console.developers.google.com
    $API_KEY="add yours";
    
    // ::fusion tables config::
    // The Fusion Tables ID (find it at fusion tables URL: the docid param)
    $TABLE_ID="add yours";
    
    // Name of columns to retrieve from the fusion table, separated by ','.
    // Below ones are mandatory for building the calendar, and its position sensitive.
    $COL_NAMES="summary,description,start,end,location,url";
    
    // Date format in the fusion table. Examples: d/M/Y, Y-M-d H:i:s, YMdTHisZ ...
    $DATE_FORMAT="add yours";
    
    // ::calendar config::
    // Name of your calendar
    $CAL_NAME="add yours";
    
    // Description of your calendar
    $CAL_DESC="add yours";
    
    // Timezone of your calendar. Examples: US/Pacific, Europe/Madrid
    $CAL_TZ="add yours";
    ?>
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-05-03
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多