I wish to encode an array of objects using JQuery.param() to then send the data via an ajax GET request.
The object is of type object and when doing console.log(JSON.stringify(obj)) i get:
[{"k":48.88975598812273,"B":2.362097778320276},{"k":48.88975598812273,"B":2.217902221679651},{"k":48.85023620829814,"B":2.217902221679651},{"k":48.85023620829814,"B":2.362097778320276},{"k":48.88975598812273,"B":2.362097778320276}]
When using JQuery.param(obj), it returns each value as undefined:
undefined=&undefined=&undefined=&undefined=&undefined=
I have read similar posts whereby an array of objects is incorrectly formed, however cannot see how this is malformed.
Can anyone advise?