Hi in my web extension I have a button, which I programmatically create a file for download when the user clicks it.
Here is my code: a.click()
However, this does nothing when I do it within the popup. It works fine on the main Safari webpage. Am I doing something wrong?
Post
Replies
Boosts
Views
Activity
Hi All. I am building a safari app extension which needs to make several HTTP requests from the background script. The HTTP requests need to use the Cookies that exist on my webpage.
When I make the requests from my background script, I see 3 of my 4 cookies are added to the request cookie header, but the 4th cookie is not there. The 4th cookie has SameSite=Lax which seems to be the issue. When I manually change Lax to none, in my webpage's cookie storage, then the request goes through successfully from my background script.
Does anyone know if there is a way to get/use cookies labeled as SameSite=Lax in my background script? I tried the broswer.cookies API, but it seems that the API will only retrieve non HttpOnly cookies, and my cookie has HttpOnly enabled as well, so this does not work.
How can I make requests from my background script that need to use cookies from my webpage?
P.S. This works in my chrome extension just fine, but it seems Safari has some restrictions
Thanks in Advance :)