[limb-svn] r6866 - 3.x/trunk/limb/net/src
svn at limb-project.com
svn at limb-project.com
Fri Mar 28 17:40:33 MSK 2008
Author: korchasa
Date: 2008-03-28 17:40:33 +0300 (Fri, 28 Mar 2008)
New Revision: 6866
URL: http://fisheye.limb-project.com/changelog/limb/?cs=6866
Modified:
3.x/trunk/limb/net/src/lmbHttpResponse.class.php
Log:
-- added getCookies() and removeCookie() methods to lmbHttpResponse class
Modified: 3.x/trunk/limb/net/src/lmbHttpResponse.class.php
===================================================================
--- 3.x/trunk/limb/net/src/lmbHttpResponse.class.php 2008-03-28 10:47:33 UTC (rev 6865)
+++ 3.x/trunk/limb/net/src/lmbHttpResponse.class.php 2008-03-28 14:40:33 UTC (rev 6866)
@@ -2,9 +2,9 @@
/*
* Limb PHP Framework
*
- * @link http://limb-project.com
+ * @link http://limb-project.com
* @copyright Copyright © 2004-2007 BIT(http://bit-creative.com)
- * @license LGPL http://www.gnu.org/copyleft/lesser.html
+ * @license LGPL http://www.gnu.org/copyleft/lesser.html
*/
lmb_require('limb/core/src/exception/lmbException.class.php');
lmb_require('limb/net/src/lmbHttpRedirectStrategy.class.php');
@@ -182,7 +182,7 @@
{
$this->_ensureTransactionStarted();
- $this->cookies[] = array('name' => $name,
+ $this->cookies[$name] = array('name' => $name,
'value' => $value,
'expire' => $expire,
'path' => $path,
@@ -190,6 +190,19 @@
'secure' => $secure);
}
+ function getCookies()
+ {
+ return $this->cookies;
+ }
+
+ function removeCookie($name)
+ {
+ if(isset($this->cookies[$name]))
+ unset($this->cookies[$name]);
+
+ $this->setCookie($name, '', 1);
+ }
+
function readFile($file_path)
{
$this->_ensureTransactionStarted();
@@ -255,4 +268,3 @@
$this->start();
}
}
-
More information about the limb-svn
mailing list