久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    <bdo id='0sqx4'></bdo><ul id='0sqx4'></ul>
  • <tfoot id='0sqx4'></tfoot>

  • <legend id='0sqx4'><style id='0sqx4'><dir id='0sqx4'><q id='0sqx4'></q></dir></style></legend>
    <i id='0sqx4'><tr id='0sqx4'><dt id='0sqx4'><q id='0sqx4'><span id='0sqx4'><b id='0sqx4'><form id='0sqx4'><ins id='0sqx4'></ins><ul id='0sqx4'></ul><sub id='0sqx4'></sub></form><legend id='0sqx4'></legend><bdo id='0sqx4'><pre id='0sqx4'><center id='0sqx4'></center></pre></bdo></b><th id='0sqx4'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='0sqx4'><tfoot id='0sqx4'></tfoot><dl id='0sqx4'><fieldset id='0sqx4'></fieldset></dl></div>

    <small id='0sqx4'></small><noframes id='0sqx4'>

        xmlhttprequest 和 set-cookie &amp;曲奇餅

        xmlhttprequest and set-cookie amp; cookie(xmlhttprequest 和 set-cookie amp;曲奇餅)

            <tbody id='HhW94'></tbody>
        1. <legend id='HhW94'><style id='HhW94'><dir id='HhW94'><q id='HhW94'></q></dir></style></legend>
            • <i id='HhW94'><tr id='HhW94'><dt id='HhW94'><q id='HhW94'><span id='HhW94'><b id='HhW94'><form id='HhW94'><ins id='HhW94'></ins><ul id='HhW94'></ul><sub id='HhW94'></sub></form><legend id='HhW94'></legend><bdo id='HhW94'><pre id='HhW94'><center id='HhW94'></center></pre></bdo></b><th id='HhW94'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='HhW94'><tfoot id='HhW94'></tfoot><dl id='HhW94'><fieldset id='HhW94'></fieldset></dl></div>
            • <small id='HhW94'></small><noframes id='HhW94'>

              <tfoot id='HhW94'></tfoot>

                <bdo id='HhW94'></bdo><ul id='HhW94'></ul>
                • 本文介紹了xmlhttprequest 和 set-cookie &amp;曲奇餅的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我想我誤解了使用 xmlhttprequest 管理 cookie.我有一個響應(yīng) XMLHttpRequest 用 javascript 制作的服務(wù)器,我的服務(wù)器返回 Allow-Control-Access-Origin, Access-Control-Allow-HeadersAccess-Control-Expose-HeadersAccess-Control-Allow-Credentials 標頭的值正確.

                  i think i misunderstood the management of cookies with xmlhttprequest. I have a server that response to the XMLHttpRequest made in javascript, my server returns Allow-Control-Access-Origin, Access-Control-Allow-Headers, Access-Control-Expose-Headers and Access-Control-Allow-Credentials headers with the correct value.

                  我正在使用 javascript 在服務(wù)器中進行 Digest Authenticate,沒問題,我從服務(wù)器接收到 WWW-Authenticate 標頭,我處理并向服務(wù)器發(fā)送 Authorization 標頭所有的摘要響應(yīng),一切正常.問題是,當摘要挑戰(zhàn)成功時,我的服務(wù)器返回一個 Set-Cookie 標頭,我必須獲取它并添加到我所有 xhr 請求的其余部分.瀏覽器(使用 Chromium 和 Chrome)不允許我訪問標題:

                  I'm doing a Digest Authenticate in a server with javascript, no problem in that, i receive ok the WWW-Authenticate header from server, i process and send to the server the Authorization header with all the digest-response and everything ok. The problem is, that when the digest-challenge is succesful, my server returns a Set-Cookie Header, i have to get it and add to the rest of all of my xhr request. The browser (using Chromium and Chrome) not let me access to the header doing:

                  xhr.getResponseHeader("Set-Cookie");
                  

                  好的,在 XMLHTTPREQUEST Level 2 中它說:從響應(yīng)中返回所有標頭, 字段名稱為 Set-Cookie 或 Set-Cookie2 的除外"好的,所以我不能接受,但是有什么方法?將 Chrome Api 用于 cookie(目前我沒有讀到關(guān)于它的注意事項),但我想盡可能采用標準方式.與:

                  Ok, in the XMLHTTPREQUEST Level 2 it says: "Returns all headers from the response, with the exception of those whose field name is Set-Cookie or Set-Cookie2" Ok, so i cant take it, but what are the ways? Using the Chrome Api for cookies (at the moment i dont read noting about it), but i want to do for a standard manner as posible. With the:

                  xhr.withCredentials = true;
                  

                  表示瀏覽器自動獲取set-cookie并發(fā)送cookie headers??

                  means that the browser automatically get the set-cookie and send in cookie headers??

                  推薦答案

                  來自 CORS 規(guī)范 http://www.w3.org/TR/cors/#make-a-request-steps:

                  From CORS spec http://www.w3.org/TR/cors/#make-a-request-steps:

                  每當應(yīng)用發(fā)出請求的步驟時,從原始來源中獲取請求 URL,并設(shè)置手動重定向標志,如果設(shè)置了省略憑據(jù)標志,則設(shè)置阻止 cookie 標志.使用方法請求方法,實體主體請求實體主體,包括作者請求標頭,如果未設(shè)置省略憑據(jù)標志,則包括用戶憑據(jù).如果源源是全局唯一標識符,則排除 Referer 標頭.

                  Whenever the make a request steps are applied, fetch the request URL from origin source origin with the manual redirect flag set, and the block cookies flag set if the omit credentials flag is set. Use method request method, entity body request entity body, including the author request headers, and include user credentials if the omit credentials flag is unset. Exclude the Referer header if source origin is a globally unique identifier.

                  正如您所說 - 如果您使用 withCredentials,瀏覽器會添加 cookie.

                  As you correctly says - cookies are added by browser if you use withCredentials.

                  這篇關(guān)于xmlhttprequest 和 set-cookie &amp;曲奇餅的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Browser waits for ajax call to complete even after abort has been called (jQuery)(即使在調(diào)用 abort (jQuery) 之后,瀏覽器也會等待 ajax 調(diào)用完成)
                  JavaScript innerHTML is not working for IE?(JavaScript innerHTML 不適用于 IE?)
                  XMLHttpRequest cannot load, No #39;Access-Control-Allow-Origin#39; header is present on the requested resource(XMLHttpRequest 無法加載,請求的資源上不存在“Access-Control-Allow-Origin標頭) - IT屋-程序員軟件開發(fā)技術(shù)分
                  Is it possible for XHR HEAD requests to not follow redirects (301 302)(XHR HEAD 請求是否有可能不遵循重定向 (301 302))
                  NETWORK_ERROR: XMLHttpRequest Exception 101(NETWORK_ERROR:XMLHttpRequest 異常 101)
                  XMLHttpRequest 206 Partial Content(XMLHttpRequest 206 部分內(nèi)容)

                    <tbody id='xgpuv'></tbody>

                      <bdo id='xgpuv'></bdo><ul id='xgpuv'></ul>

                      1. <small id='xgpuv'></small><noframes id='xgpuv'>

                        <i id='xgpuv'><tr id='xgpuv'><dt id='xgpuv'><q id='xgpuv'><span id='xgpuv'><b id='xgpuv'><form id='xgpuv'><ins id='xgpuv'></ins><ul id='xgpuv'></ul><sub id='xgpuv'></sub></form><legend id='xgpuv'></legend><bdo id='xgpuv'><pre id='xgpuv'><center id='xgpuv'></center></pre></bdo></b><th id='xgpuv'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='xgpuv'><tfoot id='xgpuv'></tfoot><dl id='xgpuv'><fieldset id='xgpuv'></fieldset></dl></div>

                          <legend id='xgpuv'><style id='xgpuv'><dir id='xgpuv'><q id='xgpuv'></q></dir></style></legend>
                          <tfoot id='xgpuv'></tfoot>
                            主站蜘蛛池模板: 久久久精彩视频 | 免费国产一区二区 | 久久国 | 国产精品久久久久久久久久久久久 | 亚洲激精日韩激精欧美精品 | 国产ts人妖系列高潮 | 国产精品久久国产精品 | 日韩精品免费视频 | 色伊人久久 | 五月婷婷激情 | 久久久久久久久99精品 | 久久久久网站 | 日韩波多野结衣 | 羞羞视频在线观看免费观看 | 天堂综合网 | 国产精品久久久久久久久久妞妞 | 亚洲成人在线网 | 亚洲国产成人精品久久 | 日韩激情视频一区 | 欧美亚洲高清 | 97色在线观看免费视频 | 久久国产综合 | 全免费a级毛片免费看视频免 | 日韩一区二区三区四区五区六区 | 精品一级 | 超碰520 | 色久电影 | 成人午夜性成交 | 免费在线观看一区二区 | 亚洲精品在线免费播放 | 国产成人午夜精品影院游乐网 | 在线观看黄视频 | 日韩欧美视频在线 | 欧美高清视频 | 国产精品一区二区欧美黑人喷潮水 | 久久中文字幕一区 | 亚洲1区| 国产一级久久久久 | 国产1区2区 | 成人在线精品视频 | 国产精品国产自产拍高清 |