PageSourceSearch

https://www.sywgqh.com.cn/portal/pc/javascript/jquery-submit/ajax/ajax.js

js sywgqh.com.cn collected 2026-10-08 06:27:50 UTC 2,217 bytes, 100 lines download raw bytes

1/**
2 ***********************************************
3 * Copyright (c)  by goldensoft
4 * All right reserved.
5 * Create Date: 2012-02-09
6 * Create Author: huangxin
7 * File Name:  ajax请求
8 * Last version:  1.0
9 * Function:
10 * Last Update Date:
11 * Change Log:
12 *************************************************
13 */
14 
15/**
16 * ajax请求
17 * url: 请求路径
18 * jsondatas: 请求参数值(json格式)
19 * callback: 响应时回调函数
20 * ajaxMode: 是否使用ajax模式提交,默认为true
21 */
22
23var galdenAjax = function(url, jsondatas, callback,ajaxMode) {
24
25	if(ajaxMode != true){
26		ajaxMode = false;
27	 }
28	$.ajax({
29		type: "POST",
30		url: url,
31		async: ajaxMode,
32		data: {
33			argsjson: jsondatas
34		},
35		cache: false,
36		datatype: 'json',
37		contentType: "application/x-www-form-urlencoded;charset=UTF-8",
38		success: function(data, textStatus)
39		 {
40			ajaxjson = eval(data);
41			if ((typeof(callback) == "object") && (callback != null))
42			 {
43				if (typeof(callback.onSuccess) == "function")
44				 callback.onSuccess(ajaxjson);
45			}
46			
47		}
48		,
49		error: function(xmlR, status, e)
50		 {
51			if (typeof(callback) == "object")
52			 {
53				if (typeof(callback.onFail) == "function")
54				 callback.onFail(xmlR, status, e);
55			}
56		}
57	});
58}
59/**
60 * ajax请求2
61 * url: 请求路径
62 * datas: 请求参数值({param1:value1,param2:value2,})
63 * callback: 响应时回调函数
64 * ajaxMode: 是否使用ajax模式提交,默认为true
65 */
66var galdenHtmlAjax = function(url, datas, callback,ajaxMode) {
67
68	if(ajaxMode != true){
69		ajaxMode = false;
70	 }
71	$.ajax({
72		type: "POST",
73		url: url,
74		async: ajaxMode,
75		data: datas,
76		cache: false,
77		datatype: 'html',
78		contentType: "application/x-www-form-urlencoded;charset=UTF-8",
79		success: function(data, textStatus)
80		 {
81			if ((typeof(callback) == "object") && (callback != null))
82			 {
83				if (typeof(callback.onSuccess) == "function")
84				 callback.onSuccess(data);
85			}
86			
87		}
88		,
89		error: function(xmlR, status, e)
90		 {
91			if (typeof(callback) == "object")
92			 {
93				if (typeof(callback.onFail) == "function")
94				 callback.onFail(xmlR, status, e);
95			}
96		}
97	});
98}
99
100

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.