summaryrefslogtreecommitdiff
path: root/framework/Web/THttpRequest.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web/THttpRequest.php')
-rw-r--r--framework/Web/THttpRequest.php20
1 files changed, 20 insertions, 0 deletions
diff --git a/framework/Web/THttpRequest.php b/framework/Web/THttpRequest.php
index fbceef38..925160c8 100644
--- a/framework/Web/THttpRequest.php
+++ b/framework/Web/THttpRequest.php
@@ -958,6 +958,10 @@ class THttpCookie extends TComponent
* @var boolean whether cookie should be sent via secure connection
*/
private $_secure=false;
+ /**
+ * @var boolean if true the cookie value will be unavailable to JavaScript
+ */
+ private $_httpOnly=false;
/**
* Constructor.
@@ -1003,6 +1007,22 @@ class THttpCookie extends TComponent
}
/**
+ * @return boolean if true the cookie value will be unavailable to JavaScript
+ */
+ public function getHttpOnly()
+ {
+ return $this->_httpOnly;
+ }
+
+ /**
+ * @param boolean $value if true the cookie value will be unavailable to JavaScript
+ */
+ public function setHttpOnly($value)
+ {
+ $this->_httpOnly = TPropertyValue::ensureBoolean($value);
+ }
+
+ /**
* @return string the name of the cookie
*/
public function getName()