jQuery序列化和反序列化 [英] jQuery serialize and unserialize
本文介绍了jQuery序列化和反序列化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想使用jQuery序列化和反序列化表单.
I want to serialize and un-serialize a form with jQuery.
如何以序列化方式获取所有元素的所有属性?
How can I get all attributes of all elements in a serialized way?
推荐答案
jQuery具有serialize
函数.
jQuery has a serialize
function.
$("#form").serialize(); // Returns serialized string
参考: http://api.jquery.com/serialize/
这篇关于jQuery序列化和反序列化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文