mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-05-31 03:34:18 +00:00
Add the user-agent string into the request object.
This commit is contained in:
parent
541de9650a
commit
4d0dc4fe78
@ -28,6 +28,16 @@ class CalDAVRequest
|
||||
{
|
||||
var $options;
|
||||
|
||||
/**
|
||||
* The raw data sent along with the request
|
||||
*/
|
||||
var $raw_post;
|
||||
|
||||
/**
|
||||
* The HTTP request method: PROPFIND, LOCK, REPORT, OPTIONS, etc...
|
||||
*/
|
||||
var $method;
|
||||
|
||||
/**
|
||||
* The depth parameter from the request headers, coerced into a valid integer: 0, 1
|
||||
* or DEPTH_INFINITY which is defined above. The default is set per various RFCs.
|
||||
@ -39,6 +49,11 @@ class CalDAVRequest
|
||||
*/
|
||||
var $principal;
|
||||
|
||||
/**
|
||||
* The user agent making the request.
|
||||
*/
|
||||
var $user_agent;
|
||||
|
||||
/**
|
||||
* Create a new CalDAVRequest object.
|
||||
*/
|
||||
@ -55,6 +70,8 @@ class CalDAVRequest
|
||||
}
|
||||
$this->method = $_SERVER['REQUEST_METHOD'];
|
||||
|
||||
$this->user_agent = ((isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : "Probably Mulberry"));
|
||||
|
||||
/**
|
||||
* A variety of requests may set the "Depth" header to control recursion
|
||||
*/
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user