Declaration
public static IHttpUrl WithParents(
this IHttpUrl url,
int levels,
string pathOrSubdomain,
bool useSubdomain = false,
bool retainQueryParams = false
)Summary
Changes a URL’s subpath or subdomain relative to the specified number of URL resolvers.
Parameters
| this IHttpUrl | url |
The URL to modify. |
| int | levels |
The number of URL resolvers to rewind. |
| string | pathOrSubdomain |
The new subpath or subdomain, without any slashes or dots. |
| bool | useSubdomain |
If true, the subdomain is changed; if false (default), the path is changed. |
| bool | retainQueryParams |
If true, the query parameters are retained; if false (default), they are removed. |
Returns
The new URL.