import v1.1.0_RC2 | 2009-09-20

This commit is contained in:
2019-07-17 22:19:00 +02:00
parent 3b7ba80568
commit 38c146901c
2504 changed files with 101817 additions and 62316 deletions

View File

@ -15,9 +15,9 @@
* @category Zend
* @package Zend_XmlRpc
* @subpackage Value
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
* @version $Id: String.php 9095 2008-03-30 18:52:31Z thomas $
* @version $Id: String.php 17759 2009-08-22 21:26:21Z lars $
*/
@ -29,7 +29,7 @@ require_once 'Zend/XmlRpc/Value/Scalar.php';
/**
* @package Zend_XmlRpc
* @subpackage Value
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_XmlRpc_Value_String extends Zend_XmlRpc_Value_Scalar
@ -45,7 +45,7 @@ class Zend_XmlRpc_Value_String extends Zend_XmlRpc_Value_Scalar
$this->_type = self::XMLRPC_TYPE_STRING;
// Make sure this value is string and all XML characters are encoded
$this->_value = $this->_xml_entities($value);
$this->_value = $this->_escapeXmlEntities($value);
}
/**
@ -56,19 +56,7 @@ class Zend_XmlRpc_Value_String extends Zend_XmlRpc_Value_Scalar
*/
public function getValue()
{
return html_entity_decode($this->_value, ENT_QUOTES, 'UTF-8');
return $this->_decodeXmlEntities($this->_value);
}
/**
* Make sure a string will be safe for XML, convert risky characters to HTML entities
*
* @param string $str
* @return string
*/
private function _xml_entities($str)
{
return htmlentities($str, ENT_QUOTES, 'UTF-8');
}
}