Edit this page

up.Params up.Params.prototype.toQuery(params)
Instance method

Returns an query string for this up.Params instance.

The keys and values in the returned query string will be percent-encoded. Non-primitive values (like File will be omitted from the retuned query string.

Example

var params = new up.Params({ foo: 'bar', baz: 'bam' })
var query = params.toQuery()

// query is now: 'foo=bar&baz=bam'

Parameters

params
required

the params to convert


Return value

a query string built from the given params

string