Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function block_windows() {
- if( preg_match( '/win/i', $_SERVER['HTTP_USER_AGENT'] ) ) {
- //echo 'windows';
- wp_die('Sorry, you need to be linux user to visit the blog');
- } else {
- //echo 'linux';
- }
- }
- add_action( 'init', 'block_windows' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement