dojo.queryToObject
<script src="../../js/dojo.js"></script>
defined in dojo/_base/xhr.js
This string:
"foo=bar&foo=baz&thinger=%20spaces%20=blah&zonk=blarg&"
results in this object structure:
{
foo: [ "bar", "baz" ],
thinger: " spaces =blah",
zonk: "blarg"
}
Note that spaces and other urlencoded entities are correctly handled.
Usage
function (/*String*/ str) (view source)
parameter | type | description |
---|---|---|
str | String |