public function get_provider( $url ) {

		$provider = false;

		foreach ( $this->providers as $matchmask => $data ) {
			if ( isset( $data['host'] ) ) {
				unset( $data['host'] );
			}
			reset( $data );

			list( $providerurl, $regex ) = $data;

			$match = $matchmask;

			// Turn the asterisk-type provider URLs into regex
			if ( ! $regex ) {
				$matchmask = '#' . str_replace( '___wildcard___', '(.+)', preg_quote( str_replace( '*', '___wildcard___', $matchmask ), '#' ) ) . '#i';
				$matchmask = preg_replace( '|^#http\\\://|', '#https?\://', $matchmask );
			}

			if ( preg_match( $matchmask, $url ) ) {
				$provider = $match;

				break;
			}
		}//end foreach

		return $provider;
	}