SetQuery sets the query parameter key to value, replacing any existing value.
(key, value string)
| 85 | |
| 86 | // SetQuery sets the query parameter key to value, replacing any existing value. |
| 87 | func (u *MutableSafeURL) SetQuery(key, value string) { |
| 88 | if u.query == nil { |
| 89 | u.query = url.Values{} |
| 90 | } |
| 91 | u.query.Set(key, value) |
| 92 | } |
| 93 | |
| 94 | // String renders the full URL. Path components and query parameters are URL encoded |
| 95 | // (aka percent-encoded) while the host prefix is included as given. The zero value |