You can pass no parameters or pass either a new filter key or sort key to build a new query string, leaving the
other properties intact.
public static getSortFilterQueryString ( string $selectedSort, array $selectedFilters, string $sortKeyToSet = '', array $filterKeysToSet = [] ) : string | ||
$selectedSort | string | |
$selectedFilters | array | |
$sortKeyToSet | string | The key name of the sort in the sorts array. |
$filterKeysToSet | array | An array of filters, where the key is the key of the filterSet in the filters array and the value is the key of the filter. |
return | string | The current or amended query string for sort and filter. |