Store white listed search query strings in sessionStorage.
- 0.1.0
-
7.1
-
7.0
- Squarespace plan that supports JavaScript.
-
CDN Hosted
Use this option for the quickest way to install this effect (files hosted externally on the jsDelivr, a CDN)
-
Options
-
Page Specific
Use this option if you want to have this effect on only one Page.
-
Add code from file query string keys to sessionStorage options.html to Page Settings > Advanced > Page Header Code Injection for the Page. Read the code for instructions within.
-
Add the following code to Page Settings > Advanced > Page Header Code Injection for the Page.
<!-- begin TWC Page Query String Keys to sessionStorage --> <!-- License < https://github.com/tomsWebConsulting/twcsl/blob/main/LICENSE.txt#L1 > --> <script src="https://cdn.jsdelivr.net/gh/tomsWebConsulting/twcsl@f2e12e40bfd48fa5d650480d1510f5b6e1f00f3e/Page/Page%20Query%20String%20Keys%20to%20sessionStorage/query%20string%20keys%20to%20sessionStorage.min.js" type="module"></script> <!-- end TWC Page Query String Keys to sessionStorage -->
-
Refer to per-page code injection for details.
-
-
Site-wide
Use this option if you want to have this effect on all Pages.
-
v7.1
-
Add code from file query string keys to sessionStorage options.html to Website > Pages > Custom Code > Code Injection > FOOTER. Read the code for instructions within.
-
Add the following code to Website > Pages > Custom Code > Code Injection > FOOTER.
<!-- begin TWC Page Query String Keys to sessionStorage --> <!-- License < https://github.com/tomsWebConsulting/twcsl/blob/main/LICENSE.txt#L1 > --> <script src="https://cdn.jsdelivr.net/gh/tomsWebConsulting/twcsl@f2e12e40bfd48fa5d650480d1510f5b6e1f00f3e/Page/Page%20Query%20String%20Keys%20to%20sessionStorage/query%20string%20keys%20to%20sessionStorage.min.js" type="module"></script> <!-- end TWC Page Query String Keys to sessionStorage -->
-
-
v7.0
-
Add code from file query string keys to sessionStorage options.html to Website > Pages > Website Tools > Custom Code > Code Injection > FOOTER. Read the code for instructions within.
-
Add the following code to Website > Pages > Website Tools > Custom Code > Code Injection > FOOTER.
<!-- begin TWC Page Query String Keys to sessionStorage --> <!-- License < https://github.com/tomsWebConsulting/twcsl/blob/main/LICENSE.txt#L1 > --> <script src="https://cdn.jsdelivr.net/gh/tomsWebConsulting/twcsl@f2e12e40bfd48fa5d650480d1510f5b6e1f00f3e/Page/Page%20Query%20String%20Keys%20to%20sessionStorage/query%20string%20keys%20to%20sessionStorage.min.js" type="module"></script> <!-- end TWC Page Query String Keys to sessionStorage -->
-
-
Refer to Add code to code injection for details.
-
-
-
-
On-site
Use this option to install the full code of this effect (files hosted on your site).
-
Page Specific
Use this option if you want to have this effect on only one Page.
-
Add code from file query string keys to sessionStorage options.html to Page Settings > Advanced > Page Header Code Injection for the Page. Read the code for instructions within.
-
Add code from file query string keys to sessionStorage.html to Page Settings > Advanced > Page Header Code Injection for the Page.
-
Refer to per-page code injection for details.
-
-
Site-wide
Use this option if you want to have this effect on all Pages.
-
v7.1
-
Add code from file query string keys to sessionStorage options.html to Website > Pages > Custom Code > Code Injection > FOOTER. Read the code for instructions within.
-
Add code from file query string keys to sessionStorage.html to Website > Pages > Website Tools > Custom Code > Code Injection > FOOTER.
-
-
v7.0
-
Add code from file query string keys to sessionStorage options.html to Page Settings > Advanced > Page Header Code Injection for the Page. Read the code for instructions within.
-
Add code from file query string keys to sessionStorage.html to Website > Pages > Website Tools > Custom Code > Code Injection > FOOTER.
-
-
Refer to Add code to code injection.
-
-
This effect is meant as a base for other effects.
This effect does not create persistant query string parameters across all the URLs of your site. Rather if you hit a page on your site with a query string that has a white listed parameter a key/value pair it will be stored in sessionStorage.
For example if the URL is < /my-page?utm_source=my-value > then a key of twc-qskts-utm_source with a value of my-value will be stored.
Please consider making a donation.
-
2026-08-19
- initial version