WebPagetest Forums
Scripting setCookie name, domain, value - Printable Version

+- WebPagetest Forums (https://www.webpagetest.org/forums)
+-- Forum: WebPagetest (/forumdisplay.php?fid=7)
+--- Forum: General Discussion (/forumdisplay.php?fid=25)
+--- Thread: Scripting setCookie name, domain, value (/showthread.php?tid=13528)



Scripting setCookie name, domain, value - kohikudasai - 02-02-2015 05:54 AM

Hello, not having much luck scripting a location cookie for a test.

In this case I need to set the domain of the cookie, in addition to a name (MYlocation) and value (ZIP=98006)

The examples provide only show domain and path, and my trial and error has not been successful. Please advise.

The scripting WIKi refers to a desktop version of pagetest (file->Runscript) that sounds like it might allow for testing and troubleshooting scripts... if so is that available for download? Thanks


RE: Scripting setCookie name, domain, value - sigurdur - 02-03-2015 02:38 AM

I don't know what the desktop version is, but the documentation is pretty straightforward on how this scripting works

If you want to set a cookie, the documentation shows you exactly how to do it:
https://sites.google.com/a/webpagetest.org/docs/using-webpagetest/scripting#TOC-setCookie

What is the cookie supposed to contain?