摘要: url: 要求为String类型的参数,(默认为当前页地址)发送请求的地址。type: 要求为String类型的参数,请求方式(post或get)默认为get。注意其他http请求方法,例如put和delete也可以使用,但仅部分浏览器支持。timeout: 要求为Number类型的参数,设置请求超时时间(毫秒)。此设置将覆盖$.ajaxSetup()方法的全局设置。async:要求为Boolean类型的参数,默认设置为true,所有请求均为异步请求。如果需要发送同步请求,请将此选项设置为false。注意,同步请求将锁住浏览器,用户其他操作必须等待请求完成才可以执行。cache:要求为Bool 阅读全文
posted @ 2013-07-10 16:30 奔跑的黑马 阅读(205) 评论(0) 推荐(0)
摘要: 之前做的一个项目当中要向网站发送请求,然后网站返回给我一个Json格式的数据,对Json格式数据进行处理请求方法如下public string GetPage(string requestUrl) { Stream instream = null; StreamReader sr = null; HttpWebResponse response = null; HttpWebRequest request = null; // 准备请求... try... 阅读全文
posted @ 2013-07-04 16:43 奔跑的黑马 阅读(6193) 评论(3) 推荐(1)
摘要: 1.C#实现方法代码Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->using System;using System.Collections.Generic;using System.Text;using System.Net;using System.IO;using System.Web.Services.Description;using System.CodeDom;using Microsoft.CSharp;using Syst 阅读全文
posted @ 2013-07-04 16:00 奔跑的黑马 阅读(397) 评论(0) 推荐(0)