jQuery Miscparam()Method

jQuery 杂项方法jQuery Misc Methods

Example

Output the result of serializing the object:

$("button").click(function(){
$("div").text($.param(personObj));
});

Try it Yourself »

Definition and Usage

The param() method creates a serialized representation of an array or object.

The serialized values can be used in the URL query string when making AJAX requests.


Syntax

$.param(object,trad)

Parameter Description
object Required. Specifies an array or object to serialize.
trad Optional. A Boolean value specifying whether to use the traditional style of parameter serialization.


jQuery 杂项方法jQuery Misc Methods

Other Extensions