/* 
 * Patch for filter_var()
 */
if(!function_exists('filter_var')){
	
	define('FILTER_VALIDATE_IP', 'ip');
	define('FILTER_FLAG_IPV4', 'ipv4');
	define('FILTER_FLAG_IPV6', 'ipv6');
	define('FILTER_VALIDATE_EMAIL', 'email');
	define('FILTER_FLAG_EMAIL_UNICODE', 'unicode');
	
	function filter_var($variable, $filter, $option = false){
		if($filter == 'ip'){
			if($option == 'ipv4'){
				if(preg_match("/(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})/", $variable, $matches)){
					$variable = $matches[1];
					return $variable;
				}
			}
			if($option == 'ipv6'){
				if(preg_match("/\s*(([:.]{0,7}[0-9a-fA-F]{0,4}){1,8})\s*/", $variable, $matches)){
					$variable = $matches[1];
					return $variable;
				}
			}
		}
		if($filter == 'email'){
			if($option == 'unicode' || $option == false){
				if(preg_match("/\s*(\S*@\S*\.\S*)\s*/", $variable, $matches)){
					$variable = $matches[1];
					return $variable;
				}
			}
		}
	}
}
	
		 
		 
		 
		Print Page - Ridiculous claim re European tapwater 
		
	
	
		Paleo Diet: Raw Paleo Diet and Lifestyle Forum 
		Raw Paleo Diet Forums => Off Topic => Topic started by: TylerDurden on July 11, 2016, 01:22:12 am 
		
			
			
				http://www.dailymail.co.uk/travel/travel_news/article-3683193/From-Spain-France-Russia-Croatia-Countries-Europe-drink-tap-water-places-really-shouldn-t.html (http://www.dailymail.co.uk/travel/travel_news/article-3683193/From-Spain-France-Russia-Croatia-Countries-Europe-drink-tap-water-places-really-shouldn-t.html) The above article absurdly claims, for example,  that UK tapwater is fine.London tapwater, for example, is estimated to have passed through an average of 8 human bladders before it reaches one's  mouth. I should add that buying mineral water in Eastern Europe is a foolish idea unless you are absolutely certain that the bottle is still properly sealed and has not already been opened and had tapwater inserted inside.