如何谷歌浏览器的高级REST客户端进行跨域POST请求? [英] How does Google Chrome's Advanced REST client make cross domain POST requests?

查看:154
本文介绍了如何谷歌浏览器的高级REST客户端进行跨域POST请求?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何谷歌浏览器的高级REST客户端插件进行跨域POST请求?我想,也许一些与CORS,但我没有看到访问控制 - 允许 - 起源中的任何回应。这是一个链接到插件:

How does Google Chrome's ADVANCED REST CLIENT plugin make cross domain POST requests? I thought maybe something with CORS but I don't see "Access-Control-Allow-Origin" in any response. This is a link to the plugin:

<一个href="https://chrome.google.com/webstore/detail/hgmloofddffdnphfgcellkdfbfbjeloo/related?hl=en-US">https://chrome.google.com/webstore/detail/hgmloofddffdnphfgcellkdfbfbjeloo/related?hl=en-US

推荐答案

简短的回答:扩展是从正常的网页不同。他们可以在安装过程中要求额外的权限。

Short answer: Extensions are different from normal web pages. They can ask for extra permissions during the course of installation.

(略)龙的答案:的插件/扩展的主要要求是,他们能够访问不同的域。他们可以在安装过程中要求额外的权限(用户通常警告,扩展程序可以访问在这些领域数据)。

(slightly) Long answer: The main requirement of plugins/extensions is that they are able to access different domains. They can ask for extra permission during the installation (The user is typically warned that the extension can access data on those domains).

看看的<一个href="http://$c$c.google.com/p/chrome-rest-client/source/browse/trunk/RestClientApp/extension/source/manifest.json">manifest.json你说的是扩展的文件。更具体地讲:

Take a look at the manifest.json file of the extension you are talking about. More specifically:

"permissions": [
    "<all_urls>", "cookies", "history"
  ]

这篇关于如何谷歌浏览器的高级REST客户端进行跨域POST请求?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆