Skip to content

yeikos/jquery.unparam

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

jQuery.unparam v1.0

What is this?

it's a jquery plugin that inverts the $.param function (http://api.jquery.com/jQuery.param/).

How to use

$.unparam(string)

Demo online

http://jsfiddle.net/yeikos/9Sv3p/

Example

<script type="text/javascript">

	var str = 'a=one&b[]=two&b[]=three&b[c]=four';

	console.log($.unparam(str)); // {"a":"one","b":{"0":"two","1":"three","c":"four"}}
	
</script>