Merge pull request #86 from Lofanmi/iss67

fix #67
This commit is contained in:
Chino Chang
2015-12-16 22:09:28 +08:00

View File

@@ -102,6 +102,10 @@ abstract class rest
*/
public static function getAcceptType()
{
if (!isset($_SERVER['HTTP_ACCEPT'])) {
return false;
}
$type = [
'html' => 'text/html,application/xhtml+xml,*/*',
'xml' => 'application/xml,text/xml,application/x-xml',
@@ -127,6 +131,7 @@ abstract class rest
}
}
}
return false;
}
}