private function treatAsBot() {
		$ret = false;
		// exclude login page and some others
		$script = isset( $_SERVER['PHP_SELF'] ) ? basename( $_SERVER['PHP_SELF'] ) : '';
		if ( in_array( $script, array( 'wp-login.php', 'xmlrpc.php', 'wp-cron.php' ) ) ) {
			$ret = true;
		}
        // Some more checks in case above fails

		// Nothing to do if autosave.
		if ( defined( 'DOING_AUTOSAVE' ) ) {
			$ret = true;
		}

		// Nothing to do if XMLRPC request.
		if ( defined( 'XMLRPC_REQUEST' ) ) {
			$ret = true;
		}

		// No go with CRON
		if(  defined( 'DOING_CRON' ) && DOING_CRON ) {
			$ret = true;
		}

		if( is_feed() ) {
			$ret = true;
		}

		// same fo rCLI
		if ( PHP_SAPI == 'cli' || ( defined( 'WP_CLI' ) && WP_CLI ) ) {
			$ret = true;
		}

		// Ips check
		$settings = geot_settings();
		if( isset( $settings['bots_country_ips'] ) && in_array( $this->ip, textarea_to_array( $settings['bots_country_ips'] ) ) ) {
			$ret = true;
		}

		return apply_filters( 'geot/treat_request_as_bot', $ret );
	}
private function treatAsBot() {
		$ret = false;
		// exclude login page and some others
		$script = isset( $_SERVER['PHP_SELF'] ) ? basename( $_SERVER['PHP_SELF'] ) : '';
		if ( in_array( $script, array( 'wp-login.php', 'xmlrpc.php', 'wp-cron.php' ) ) ) {
			$ret = true;
		}
        // Some more checks in case above fails

		// Nothing to do if autosave.
		if ( defined( 'DOING_AUTOSAVE' ) ) {
			$ret = true;
		}

		// Nothing to do if XMLRPC request.
		if ( defined( 'XMLRPC_REQUEST' ) ) {
			$ret = true;
		}

		// No go with CRON
		if(  defined( 'DOING_CRON' ) && DOING_CRON ) {
			$ret = true;
		}

		if( is_feed() ) {
			$ret = true;
		}

		// same fo rCLI
		if ( PHP_SAPI == 'cli' || ( defined( 'WP_CLI' ) && WP_CLI ) ) {
			$ret = true;
		}

		// Ips check
		$settings = geot_settings();
		if( isset( $settings['bots_country_ips'] ) && in_array( $this->ip, textarea_to_array( $settings['bots_country_ips'] ) ) ) {
			$ret = true;
		}

		return apply_filters( 'geot/treat_request_as_bot', $ret );
	}
private function treatAsBot ( ) { $ ret = false ; // exclude login page and some others $ script = isset ( $ _SERVER [ 'PHP_SELF' ] ) ? basename ( $ _SERVER [ 'PHP_SELF' ] ) : '' ; if ( in_array ( $ script , array ( 'wp-login.php' , 'xmlrpc.php' , 'wp-cron.php' ) ) ) { $ ret = true ; } // Some more checks in case above fails // Nothing to do if autosave. if ( defined ( 'DOING_AUTOSAVE' ) ) { $ ret = true ; } // Nothing to do if XMLRPC request. if ( defined ( 'XMLRPC_REQUEST' ) ) { $ ret = true ; } // No go with CRON if ( defined ( 'DOING_CRON' ) && DOING_CRON ) { $ ret = true ; } if ( is_feed ( ) ) { $ ret = true ; } // same fo rCLI if ( PHP_SAPI == 'cli' || ( defined ( 'WP_CLI' ) && WP_CLI ) ) { $ ret = true ; } // Ips check $ settings = geot_settings ( ) ; if ( isset ( $ settings [ 'bots_country_ips' ] ) && in_array ( $ this -> ip , textarea_to_array ( $ settings [ 'bots_country_ips' ] ) ) ) { $ ret = true ; } return apply_filters ( 'geot/treat_request_as_bot' , $ ret ) ; }
Check for some urls where geotargeting should be disabled
@return bool
Check for some urls where geotargeting should be disabled