0

我正在使用带有 WASCE 服务器的 struts 框架创建 Web 应用程序。我想在用户输入用户名时加载vimeo视频。这样我就在 vimeo 开发者站点中创建了应用程序并获得了 apiKey、apiSecret、token 和 secret 值。我已将这些值应用到我的代码中。当我在本地运行时,我得到了正确的(带有视频网址)JSON 响应。

但是当我将它部署到专用服务器并检查我得到的响应时,

{"generated_in":"0.0039","stat":"fail","err":{"code":"401","expl":"The oauth_timestamp 
passed is either too far in the past or in the future. Vimeo thinks the current time is 
1379053244","msg":"Invalid \/ expired token"}}

我已经搜索了这个问题并得到了一些解决方案,如下所示。

Looks like your server's time is set incorrectly. Vimeo's API is time-sensitive to 
within a few minutes. You should be able to ask your hosting provider to 
correct the server's time.

参考: http: //community.tubepress.com/topic/287-vimeo-no-videos-to-populate-this-tubepress-gallery/ ?p=989

这样我就检查了服务器时间。我的当地时间是上午 11 点,服务器时间是下午 23 点。现在我将服务器时间更改为 11.00AM(因为 11.00AM 在 localhost 中工作)。

但我仍然遇到同样的问题。谁能告诉我可能是什么问题以及如何解决这个问题。

注意: 我已将当地时间更改为下午 23:00,并且我得到了“无效过期令牌”的回复。所以再次将其更改为上午 11 点,我得到了正确的响应。

4

0 回答 0