简体   繁体   English

将 Google 日历议程视图制作成卡片

[英]Making Google Calendar agenda view into cards

I'm using Mobirise to build our club's website, and they want to show some of our events at the top of the page.我正在使用 Mobirise 建立我们俱乐部的网站,他们希望在页面顶部显示我们的一些活动。

I thought I could make something like this, with the outer blue being where the calendar frame would end (very rough drawing, don't judge too hard).我想我可以做这样的事情,外面的蓝色是日历框架结束的地方(非常粗糙的绘图,不要太难判断)。 活动日历示例

Tockify had something pretty close, but I figured there's a way to code something like this, or perhaps another service that's free that can do this. Tockify 有一些非常接近的东西,但我认为有一种方法可以编写这样的代码,或者可能是另一种免费的服务可以做到这一点。 I would prefer not to use PHP, but embed some JavaScript into the HTML that can do this.我宁愿不使用 PHP,而是将一些 JavaScript 嵌入可以做到这一点的 HTML 中。

Thanks!谢谢!

To retrieve events from an account's calendar, you need to connect to the Google Calendar API using authorized credentials.要从帐户的日历中检索事件,您需要使用授权凭据连接到 Google 日历 API。

For this you need to create a project in Google Cloud Platform, and enable the calendar API for that project.为此,您需要在 Google Cloud Platform 中创建一个项目,并为该项目启用日历 API。 You will also need to create credentials for your app to use when making calls to the API.在调用 API 时,您还需要创建应用程序使用的凭据。

After you have a project, credentials and you have enabled the Calendar API, it is time to code a script that uses the credentials to get the data you want from the Calendar API.在您拥有项目、凭据并启用日历 API 之后,是时候编写使用凭据从日历 API 获取所需数据的脚本了。

There are several language client libraries for each developer's need.有几个语言客户端库可以满足每个开发人员的需要。 You could use JavaScript for your application.您可以将 JavaScript 用于您的应用程序。

Here is a quickstart that should get you up and running to make those Calendar API calls you are looking for.这是一个快速入门,可以帮助您启动并运行您正在寻找的日历 API 调用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM