工作灯:WL.Client.addGlobalHeader() 不起作用



当我添加行时

WL.Client.addGlobalHeader("MyCustomHeader","abcdefgh");

在我的主 js 文件中,就像这样

function wlCommonInit(){
WL.Client.addGlobalHeader("MyCustomHeader","abcdefgh");
    (...)

就像文档(http://pic.dhe.ibm.com/infocenter/wrklight/v5r0m5/topic/com.ibm.worklight.help.doc/apiref/r_wl_client_addglobalheader.html(中描述的那样,这绝对不会影响之后发送的所有请求:

GET /apps/services/preview/MobileOPMClient/common/0/default/images/icons/icon_settings.png             
HTTP/1.1
Host: localhost:8080
Connection: keep-alive
Accept: image/webp,*/*;q=0.8
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/30.0.1599.66 Safari/537.36
Referer: http://localhost:8080/apps/services/preview/MobileOPMClient/common/0/default/MobileOPMClient.html
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8,de;q=0.6
Cookie: JSESSIONID=1e1fig7holfdpeuc46w6jmrph; testcookie=oreo

为什么没有线

MyCustomHeader: abcdefgh

背景:我想允许javascript文件的本地缓存在chrome中调试它们。

斯派罗

为 WL

客户端 API 发出的请求(例如 WL(添加了全局标头。Client.connect((, WL.Client.invokeProcedure(( etc.

最新更新