CommonUtils.jsp
942 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<%--
<%@ page language="java" contentType="text/html; charset=UTF-8" %>--%>
<%--<%@ include file="/systeminfo/init_wev8.jsp" %>--%>
<%!
public static String $label(int labelId, int languageId){
return SystemEnv.getHtmlLabelName(labelId, languageId);
}
%>
<script>
jQuery(document).ready(function(){
jQuery.param = function( a ) {
var s = [];
var encode = function(str){
str = escape(str);
str = str.replace(/\+/g, '%u002B');
return str;
};
function add( key, value ){
s[ s.length ] = encode(key) + '=' + encode(value);
};
if ( jQuery.isArray(a) || a.jquery )
jQuery.each( a, function(){
add( this.name, this.value );
});
else
for ( var j in a )
if ( jQuery.isArray(a[j]) )
jQuery.each( a[j], function(){
add( j, this );
});
else
add( j, jQuery.isFunction(a[j]) ? a[j]() : a[j] );
return s.join("&").replace(/%20/g, "+");
}
});
</script>