Advertisement
Guest User

Untitled

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