Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // turn all cookies into string
- $cookie_string = implode(array_keys($_COOKIE));
- // find position of desired cookie
- $pos = strpos($cookie_string,'wp-postpass');
- // extract string starting at $pos
- $pass_cookie = substr($cookie_string,$pos);
- // set cookie to expire on browser close
- setcookie($pass_cookie,'',0);
- ?>
Advertisement
Add Comment
Please, Sign In to add comment