/** * jQuery Serialize List * Copyright (c) 2009 Mike Botsko, Botsko.net LLC * Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) * Copyright notice and license must remain intact for legal use * Version .2 * * Serialize an unordered or ordered list item. Optional ability * to determine which attributes are included. The serialization * will be read by PHP as a multidimensional array which you may * use for saving state. * * http://github.com/botskonet/jquery.serialize-list */ !function(h){h.fn.serializelist=function(e){var i,r,a,t={attributes:["id"],allow_nest:!0,prepend:"ul",att_regex:!1,is_child:!1},l=h.extend(t,e),s=l.attributes,c="",d=function(e,t){if(!l.att_regex)return t;for(r in l.att_regex)if(l.att_regex[r].att===e)return t.replace(l.att_regex[r].regex,"")};return l.is_child||(l.prepend="&"+l.prepend),this.each(function(n,e){h(e).children().each(function(e,t){if(l.allow_nest||1