HTTP/2 301
server: nginx
date: Sat, 27 Dec 2025 01:59:36 GMT
content-type: text/html; charset=UTF-8
x-olaf: ⛄
vary: accept, content-type
x-redirect-by: WordPress
location: https://developer.wordpress.org/reference/functions/wp_parse_str/
x-frame-options: SAMEORIGIN
alt-svc: h3=":443"; ma=86400
x-nc: MISS ord 1
HTTP/2 200
server: nginx
date: Sat, 27 Dec 2025 01:59:36 GMT
content-type: text/html; charset=UTF-8
vary: Accept-Encoding
x-olaf: ⛄
vary: accept, content-type
link:
; rel="https://api.w.org/"
link:
; rel="alternate"; title="JSON"; type="application/json"
link: ; rel=shortlink
x-frame-options: SAMEORIGIN
content-encoding: gzip
alt-svc: h3=":443"; ma=86400
x-nc: MISS ord 1
wp_parse_str() – Function | Developer.WordPress.org
wp_parse_str( string $input_string, array $result )
Parses a string into variables to be stored in an array.
$input_stringstringrequiredThe string to be parsed.
$resultarrayrequiredVariables will be stored in this array.
function wp_parse_str( $input_string, &$result ) {
parse_str( (string) $input_string, $result );
/**
* Filters the array of variables derived from a parsed string.
*
* @since 2.2.1
*
* @param array $result The array populated with variables.
*/
$result = apply_filters( 'wp_parse_str', $result );
}
View all references View on Trac View on GitHub
| Version | Description |
|---|
| 2.2.1 | Introduced. |
Let’s say, you have an URL with query parameters. And you need query parameter values in an Array.