IE7下ajax之open Method New的说明

open Method Assigns method, destination URL, and other optional attributes of a pending request.
Syntax

XMLHttpRequest.open(sMethod, sUrl [, bAsync] [, sUser] [, sPassword])[/pre]
Parameters

















sMethod Required. String that specifies the HTTP method used to open the connection: such as GET, POST, or HEAD. This parameter is not case-sensitive.
sUrl Required. String that specifies either the absolute or a relative URL of the XML data or server-side XML Web services.
bAsync Optional. Variant that specifies true for asynchronous operation (the call returns immediately), or false otherwise. If true, assign a callback handler to the onreadystatechange property to determine when the call has completed. If not specified, the default is true.
sUser Optional. Variant that specifies the name of the user for authentication. If this parameter is null ("") or missing and the site requires authentication, the component displays a logon window.
sPassword Optional. Variant that specifies the password for authentication. This parameter is ignored if the user parameter is null ("") or missing.
Return Value

No return value.
Remarks

open was introduced in Internet Explorer 7.
The following HTTP verbs and World Wide Web Distributed Authoring and Versioning (WebDAV) methods =700) window.open('http://msdn2.microsoft.com/en-us/library/ms536648.leave-site%28en-us,VS.85%29.gif');" src="http://msdn2.microsoft.com/en-us/library/ms536648.leave-site%28en-us,VS.85%29.gif" onload="if(this.width>'700')this.width='700';if(this.height>'700')this.height='700';" border=0> are supported:

  • GET
  • POST
  • HEAD
  • PUT
  • DELETE
  • MOVE
  • PROPFIND
  • PROPPATCH
  • MKCOL
  • COPY
  • LOCK
  • UNLOCK
  • OPTIONS
Microsoft Internet Explorer caches the results of HTTP GET requests in the Temporary Internet Files (TIF) folder. In most cases, caching improves performance for data that will not change frequently. To guarantee that the results are not cached, use POST.

=700) window.open('http://msdn2.microsoft.com/en-us/library/ms536648.UI_security_bang_16%28en-us,VS.85%29.gif');" src="http://msdn2.microsoft.com/en-us/library/ms536648.UI_security_bang_16%28en-us,VS.85%29.gif" onload="if(this.width>'700')this.width='700';if(this.height>'700')this.height='700';" border=0> Security Alert  Cross-domain, cross-port, and mixed protocol requests are not allowed. The sUrl parameter may only specify XML data files in the same domain, using the same port and protocol method, as that from which the page is served. Although this method accepts credentials passed via parameter, those credentials are not automatically sent to the server on the first request. The sUser and sPassword parameters are not transmitted unless the server challenges the client for credentials with a 401 - Access Denied response.
After calling this method, use send to send the request and data, if any, to the server.

Applies To





XMLHttpRequest
See Also

abort, onreadystatechange

(0)

相关推荐

  • IE7下ajax之open Method New的说明

    open Method Assigns method, destination URL, and other optional attributes of a pending request.Syntax XMLHttpRequest.open(sMethod, sUrl [, bAsync] [, sUser] [, sPassword])[/pre]Parameters sMethod Required. String that specifies the HTTP method used

  • Jquery在IE7下无法使用 $.ajax解决方法

    通过查看源码发现 复制代码 代码如下: // Create the request object; Microsoft failed to properly // implement the XMLHttpRequest in IE7, so we use the ActiveXObject when it is available // This function can be overriden by calling jQuery.ajaxSetup xhr:function(){ retu

  • ie7下利用ajax跨域盗取cookie的解决办法

    研究了一下午,第一个难题是ajax跨域提交数据,可以用web代理来解决,http://192.168.8.108上的a.htm代码: <script> function getXmlHttpRequest(){ if(window.ActiveXObject){ var ieArr=["Msxml2.XMLHTTP","Microsoft.XMLHTTP"]; for(var i=0;i<ieArr.length;i++) { var xmlhtt

  • jquery在ie7下选择器的问题导致append失效的解决方法

    1,有如下这样一段html 复制代码 代码如下: <div class="right"id="pending">  <table class="one"width="100%"border="0"cellspacing="0"cellpadding="0"> <tbody> </tbody> </table>

  • prototype与jquery下Ajax实现的差别

    先列举一下Ajax在Jquery和prototype中的实现. Jquery: 复制代码 代码如下: <script language="javascript"> $(function(){ var box = {}; var remoteUrl = 'index.php'; box.interval = 5*60*1000;//5分钟 box.showBoxInfo = function() { jQuery.get(remoteUrl, function(data){

  • IE下Ajax提交乱码的快速解决方法

    哈哈,试了这么多还是encodeURIComponent管用啊!!!! 在汉字的位置加个保护措施:encodeURIComponent(parentid) function loadCity(parentid) { var city = '${hotel.city}'; $.ajax({ url: './listCity.jspx?prov='+ encodeURIComponent(parentid), type: 'GET', dataType: 'JSON', timeout: 5000,

  • IE8/IE9下Ajax缓存问题

    ajax简介 AJAX即"Asynchronous Javascript And XML"(异步JavaScript和XML),是指一种创建交互式网页应用的网页开发技术. AJAX = 异步 JavaScript和XML(标准通用标记语言的子集). AJAX 是一种用于创建快速动态网页的技术. 通过在后台与服务器进行少量数据交换,AJAX 可以使网页实现异步更新.这意味着可以在不重新加载整个网页的情况下,对网页的某部分进行更新. 步入正题: 最近在做一个网站的登录注册框,前端使用了jq

  • IE8下Ajax缓存问题及解决办法

    Ajax简介 AJAX即"Asynchronous Javascript And XML"(异步JavaScript和XML),是指一种创建交互式网页应用的网页开发技术. AJAX = 异步 JavaScript和XML(标准通用标记语言的子集). AJAX 是一种用于创建快速动态网页的技术. 通过在后台与服务器进行少量数据交换,AJAX 可以使网页实现异步更新.这意味着可以在不重新加载整个网页的情况下,对网页的某部分进行更新. 下面的代码,在其他浏览器都是正常的,但是在IE8中出现诡

  • LBS BLOG在IE7下图片出现滚动条的解决方法

    今天看我自己的BLOG才发现这个问题, 怎么图片四周全是滚动条,就算是很小的一张图片, 换了FF看却很正常,就怀疑是IE7搞的鬼, 在网上搜了一搜, 还真有解决方法, 跟我一样用LBS的兄弟姐妹快更新一下自己的BLOG吧, 在IE7下真的是惨不忍睹啊. 找到class目录下的ubbcode.asp文件,修改132行, 复制代码 代码如下: var newStr='<div style="width: 100%;"><a href="'+strURL+'&qu

  • ASP.NET MVC下Ajax.BeginForm方式无刷新提交表单实例

    有时候,不得不考虑到以下场景问题: 数据库表字段会频繁更改扩展,而流行的重业务的js框架过于依赖json数据接口,导致的问题是,数据库表更改 -> 数据接口更改 -> 前段框架逻辑更改... 一不小心就陷入坑坑洼洼. 这样的话,原来纯ASP.NET MVC绑定的方式,还是可以一用的,因为该方式不用再为那么多js代码烦恼. 不好意思,前面自说自话啊,直接上干货代码了---- Ajax.BeginForm @{ Layout = null; var ajaxOptions = new AjaxOp

随机推荐