Update card.php
extended switch for using BasicAuth for Windows Phone and DigestAuth e.g. when iPhone tries to connect. Now Baikal is more flexible to support iPhone and Windows Phone on the fly.
This commit is contained in:
		
							parent
							
								
									58c58c0817
								
							
						
					
					
						commit
						987e7ec5cd
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -52,7 +52,7 @@ if(!defined("BAIKAL_CARD_ENABLED") || BAIKAL_CARD_ENABLED !== TRUE) {
 | 
			
		|||
}
 | 
			
		||||
 | 
			
		||||
# Backends
 | 
			
		||||
if( BAIKAL_DAV_AUTH_TYPE == "Basic" )
 | 
			
		||||
if( BAIKAL_DAV_AUTH_TYPE == "Basic" || preg_match('/Windows-Phone-WebDAV-Client/i', $_SERVER['HTTP_USER_AGENT']) )
 | 
			
		||||
    $authBackend = new \Baikal\Core\PDOBasicAuth($GLOBALS["DB"]->getPDO(), BAIKAL_AUTH_REALM);
 | 
			
		||||
else
 | 
			
		||||
    $authBackend = new \Sabre\DAV\Auth\Backend\PDO($GLOBALS["DB"]->getPDO());
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue