使用PHP的Google Url Shortener服务:如何使用gzip提高性能?

时间:2016-01-16 15:40:51

标签: curl gzip google-url-shortener

我在PHP代码中使用Google Url Shortener服务。

它正在运行,但我想提高性能,我已经看到文档(rif。https://developers.google.com/url-shortener/v1/performance)建议使用部分资源并使用gzip。

我采用了部分资源方法并且工作正常,但现在我也想使用gzip建议。

现在我的代码是

Accept-Encoding: gzip
User-Agent: my program (gzip)

Google文档说要使用

static mapping = {
    datasource 'example'
}

我的问题是我不知道如何在我的PHP代码中转换它......

有什么建议吗?

非常感谢你提前!!!

切萨雷

0 个答案:

没有答案