I want to remove cookies (according to certain criteria) from within a Chrome extension. According to Now the following fields have one: For my reference, a cookie looks like this: After some lawsuits and errors, I get the URL , It works for everything (probably chrome.cookies.remove this field is the
url (the URL associated with the cookie) and
names (the name of the cookie to delete the).
name, value, domain, host, path, secure, httpOnly, session, expiration date, storeId but not
url . How do I get the URL of a specific cookie, so that I can delete it?
domain: "google.com" adi = 8 & lt; Snip & gt; U " " "" "" "
leaving the file): // )
function extrapolateUrlFromCookie (cookie) {var prefix = cookie.secure? "Https: //": "http: //"; If (cookie.domain.charAt (0) == ".") Prefix + = "www"; Return prefix + cookie.domain + cookie.path; }
Comments
Post a Comment