> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # Method name: queryParams() # Method package: wixLocationFrontend # Method menu location: wixLocationFrontend --> queryParams # Method Link: https://dev.wix.com/docs/velo/apis/wix-location-frontend/query-params.md # Method Description: Gets an object used to manage the query segment of the current page's URL. # Method Code Examples: *** Note: do not assume any prop names or enum values other than the ones in the example. ## Add query parameters to the URL ```javascript import wixLocationFrontend from 'wix-location-frontend'; // ... wixLocationFrontend.queryParams.add({ "key2": "value2new", "key3": "value3" }); // URL before addition: // www.mysite.com/page?key1=value1&key2=value2 // URL will look like: // www.mysite.com/page?key1=value1&key2=value2new&key3=value3 ``` ## Remove query parameters from the URL ```javascript import wixLocationFrontend from 'wix-location-frontend'; // ... wixLocationFrontend.queryParams.remove(["key1"]); // URL before removal: // www.mysite.com/page?key1=value1&key2=value2 // URL after removal: // www.mysite.com/page?key2=value2 ``` ## Add, update, remove, and get URL query parameters ```javascript import wixLocationFrontend from 'wix-location-frontend'; $w.onReady(function () { $w("#addButton").onClick((event) => { const key = $w('#addKey').value; const value = $w('#addValue').value; if (key && value) { const toAdd = { [key]: value }; wixLocationFrontend.queryParams.add(toAdd); $w('#addKey').value = undefined; $w('#addValue').value = undefined; } }); $w("#removeButton").onClick((event) => { const paramToRemove = [$w('#removeKey').value]; wixLocationFrontend.queryParams.remove(paramToRemove); $w('#removeKey').value = undefined; }); $w("#getButton").onClick((event) => { const query = wixLocationFrontend.query; if (query) { $w('#getText').value = JSON.stringify(query, null, 2); } }); }); ``` ---