Advertisement
Guest User

Untitled

a guest
Sep 28th, 2020
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.26 KB | None | 0 0
  1. function pm_remove_emojis($regex) {
  2.     $regex = str_replace('[^', '(%f0%9f%[\w]{2}%[\w]{2}|[^', $regex);
  3.     $regex = str_replace(']/ui', '])/ui', $regex);
  4.  
  5.     var_dump($regex);
  6.  
  7.     return $regex;
  8. }
  9. add_filter('permalink_manager_sanitize_regex', 'pm_remove_emojis', 1);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement