Advertisement
Nolifeq

Untitled

Nov 22nd, 2021
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. // ==UserScript==
  2. // @name renewMCharCookie
  3. // @namespace http://czogi.usermd.net
  4. // @version 1
  5. // @description Przedłużanie ciasteczka mchar_id co refresh strony
  6. // @include /http[s]{0,1}:\/\/[a-z]{4,15}\.margonem\.pl/
  7. // @noframes
  8. // @author Czogi
  9. // @grant none
  10. // ==/UserScript==
  11.  
  12. {
  13. document.cookie?.split("; ").map((cookie) => {
  14. const [key, val] = cookie.split("=");
  15. if (key !== "mchar_id") {
  16. return;
  17. }
  18.  
  19. document.cookie = `${key}=${val}; expires=${new Date(
  20. new Date().getTime() + 604800000 // 7 dni.
  21. ).toUTCString()}; domain=.margonem.pl; path=/;`;
  22. });
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement