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

    <bdo id='6aBQb'></bdo><ul id='6aBQb'></ul>
<tfoot id='6aBQb'></tfoot>

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

      Web 應用程序中的跨源請求

      cross origin request in web application(Web 應用程序中的跨源請求)

      <tfoot id='xgPXm'></tfoot>
        1. <legend id='xgPXm'><style id='xgPXm'><dir id='xgPXm'><q id='xgPXm'></q></dir></style></legend>

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

            <small id='xgPXm'></small><noframes id='xgPXm'>

              <tbody id='xgPXm'></tbody>
              <bdo id='xgPXm'></bdo><ul id='xgPXm'></ul>

                本文介紹了Web 應用程序中的跨源請求的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                問題描述

                在我的 Tizen 系統應用程序中,我發出了一個跨源 AJAX 請求,它在 Tizen 的瀏覽器中運行良好,但是當我將其打包為 Web 應用程序時,跨源請求無法運行.我已經在模擬器和真實設備上對其進行了測試.我也使用 webkit 檢查器記錄網絡日志,截圖如下:

                In my application for Tizen system, I make a cross origin AJAX request, it works well in Tizen's browser, but when I package it as web application, the cross origin request can't work. I've tested it both on emulator and real device. I also use the webkit inspector record the network log, the screenshot is as following:

                有專家能告訴我為什么嗎?

                Could any expert tell me why?

                以下是我的代碼:

                var url = "";//this is assigned a domain which supports cross domain access according to HTML5 specification.
                var client = new XMLHttpRequest();
                client.open("GET", url, true);
                client.setRequestHeader("Accept-Language", 'en-us');
                client.onreadystatechange = function() { alert("succeed"); }
                client.send();
                

                推薦答案

                任何在外部訪問的資源都應該聲明(見訪問外部網絡資源):

                Any resource that it is accessed outside should be declared(see Accessing External Network Resources):

                默認情況下您無法訪問外部網絡資源(WARP:W3C訪問請求策略).因此,您必須請求權限小部件來檢索網絡資源.您可以通過以下方式輸入多個 URL使用訪問"選項卡上的添加"按鈕.對于每個 URL,您可以指定如果您想允許小部件訪問 URL 子域.這允許子域欄內容可以通過鼠標點擊切換.

                You cannot access external network resources by default (WARP: W3C Access Requests Policy). So, you must request permissions for the widget to retrieve network resources. You can enter several URLs by using the Add button on the Access tab. For each URL, you can indicate if you want to allow the widget to access the URL sub-domains. The Allow subdomain column contents can be toggled by mouse clicks.

                所以如果沒有訪問我們在 config.xml 中定義的案例所需的特定資源,它就無法工作:

                so it cannot work without having access to the specific resource needed in our case defined in config.xml:

                <access origin="http://url_resource" subdomains="true"/>
                

                <access origin="*" subdomains="true"/>
                

                讓一切都過去.

                這篇關于Web 應用程序中的跨源請求的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

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

                相關文檔推薦

                Browser waits for ajax call to complete even after abort has been called (jQuery)(即使在調用 abort (jQuery) 之后,瀏覽器也會等待 ajax 調用完成)
                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屋-程序員軟件開發技術分
                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 部分內容)

                    <small id='g4y24'></small><noframes id='g4y24'>

                      <tbody id='g4y24'></tbody>

                      <legend id='g4y24'><style id='g4y24'><dir id='g4y24'><q id='g4y24'></q></dir></style></legend>

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

                          主站蜘蛛池模板: 亚洲精品日韩视频 | 亚洲精品电影网在线观看 | 久久亚洲经典 | 一区二区三区四区免费视频 | 暖暖成人免费视频 | 国产欧美一区二区三区另类精品 | 精品一区二区在线观看 | h视频在线免费 | 国产精品久久久久免费 | 中文字幕久久精品 | 日美女逼逼 | 日韩精品一区二区三区中文字幕 | 国产精品福利在线 | 欧美在线一区二区三区 | 国产aa | 国产精品高清一区二区 | 午夜精品久久久久久久久久久久 | 2019精品手机国产品在线 | 成人毛片在线视频 | 久久久美女 | 日韩国产一区二区三区 | 伊人久久麻豆 | www久久爱| 日本激情视频在线播放 | 久久久国产精品 | 久精品久久 | 欧美精品在线一区 | 99re视频在线 | 国产精品18hdxxxⅹ在线 | 国产一级视频免费播放 | 亚洲一二三区免费 | 午夜欧美a级理论片915影院 | 妞干网福利视频 | 色婷婷综合久久久中字幕精品久久 | 亚洲精品久久久9婷婷中文字幕 | 在线a视频网站 | 日韩av在线免费 | 久久亚洲国产精品日日av夜夜 | 91极品欧美视频 | 一级片片| 免费午夜视频 |