Advertisement
chernov2000

Для сбора _ym_uid из cookies

Apr 12th, 2024
11
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. var ym_uid = getCookie('_ym_uid');
  2. function getCookie(name) {
  3. var matches = document.cookie.match(new RegExp(
  4. "(?:^|; )" + name.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g, '\\$1') + "=([^;]*)"
  5. ));
  6. return matches ? decodeURIComponent(matches[1]) : undefined;
  7. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement