:relfileprefix: ../../../ [#659584CC22BB0E0B94C5CDD3BD47E2CE818AA651] = Function url_base::remove_query pass:v,q[Remove the query] == Synopsis Declared in header `` [source,cpp,subs="verbatim,macros,-callouts"] ---- xref:boost/urls/url_base.adoc[url_base]& remove_query() noexcept; ---- == Description pass:v,q[If a query is present, it is removed.] pass:v,q[An empty query is distinct from having] pass:v,q[no query.] === Example [,cpp] ---- assert( url( "http://www.example.com?id=42" ).remove_query().buffer() == "http://www.example.com" ); ---- === Postconditions [,cpp] ---- this->has_query() == false && this->params().empty() ---- === Exception Safety pass:v,q[Throws nothing.] === BNF [,cpp] ---- query = *( pchar / "/" / "?" ) query-param = key [ "=" value ] query-params = [ query-param ] *( "&" query-param ) ---- === Specification * link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)] * link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)] == Return Value * ``