Version 3.17.2
Show:

querystring Module

The QueryString module adds support for serializing JavaScript objects into query strings and parsing JavaScript objects from query strings format.

The QueryString namespace is added to your YUI instance including static methods Y.QueryString.parse(..) and Y.QueryString.stringify(..).

The querystring module is a alias for querystring-parse and querystring-stringify.

As their names suggest, querystring-parse adds support for parsing Query String data (Y.QueryString.parse) and querystring-stringify for serializing JavaScript data into Query Strings (Y.QueryString.stringify). You may choose to include either of the submodules individually if you don't need the complementary functionality, or include the rollup for both.

This module provides the following classes:

This module is a rollup of the following modules:

  • querystring-parse
    Provides Y.QueryString.parse method to accept Query Strings and return native JavaScript objects.
  • querystring-parse-simple

    Provides Y.QueryString.parse method for converting Query Strings to an object. This is a simpler implementation than the full querystring-parse.

    Because some things may require basic query string escaping functionality, this module provides the bare minimum functionality (decoding a hash of simple values), without the additional support for arrays, objects, and so on.

    This provides a friendly way to deserialize basic query strings, without necessitating a lot of code for simple use-cases.

  • querystring-stringify
    Provides Y.QueryString.stringify method for converting objects to Query Strings.
  • querystring-stringify-simple

    Provides Y.QueryString.stringify method for converting objects to Query Strings. This is a subset implementation of the full querystring-stringify.

    This module provides the bare minimum functionality (encoding a hash of simple values), without the additional support for nested data structures. Every key-value pair is encoded by encodeURIComponent.

    This module provides a minimalistic way for io to handle single-level objects as transaction data.