Advertisement
Guest User

Untitled

a guest
Sep 15th, 2015
74
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. // add function in FUNCTIONS.php
  3. add_action( 'mobile_redirect' );
  4. if ( is_page( 'Download' )
  5.  
  6.     } else {
  7.     require_once( get_template_directory() . '/mobile_detect/Mobile_Detect.php');
  8.  
  9. global $detect;
  10. if ( class_exists( 'Mobile_Detect' ) ):
  11.         $detect = new Mobile_Detect;
  12. endif;
  13.  
  14. if( $detect->isiOS() ) {wp_redirect( 'https://itunes.apple.com/au/app/stashd/id714814803?mt=8'); exit(0); };
  15.     }
  16. }
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement