wpseek.com
A WordPress-centric search engine for devs and theme authors



build_query › WordPress Function

Since2.3.0
Deprecatedn/a
build_query ( $data )
Parameters:
  • (array) $data URL-encode key/value pairs.
    Required: Yes
Links:
See:
Returns:
  • (string) URL-encoded string.
Defined at:
Codex:

Builds URL query based on an associative and, or indexed array.

This is a convenient function for easily building url queries. It sets the separator to '&' and uses _http_build_query() function.


Source

function build_query( $data ) {
	return _http_build_query( $data, null, '&', '', false );
}