}
/**
+ * decode json string or
+ *
+ * Prepare function input to be an array. Input maybe already an array or (empty) text.
+ * Starting PHP 7 Zend_Json::decode can't handle empty strings.
+ *
+ * @param $jsonOrArray
+ * @return mixed
+ * @throws Zend_Json_Exception
+ */
+ public static function jsonDecode($jsonOrArray)
+ {
+ if (is_array($jsonOrArray)) {
+ return $jsonOrArray;
+ } else if (trim($jsonOrArray) == '') {
+ return Zend_Json::decode("{}");
+ } else {
+ return Zend_Json::decode($jsonOrArray);
+ }
+ }
++
++ /**
+ * removes characters that are illegal in XML (those characters are not even in CDATA allowed)
+ *
+ * @param string $string
+ * @return string
+ */
+ public static function removeIllegalXMLChars($string)
+ {
+ return preg_replace('/[^\x09\x0A\x0D\x20-\x{D7FF}\x{E000}-\x{FFFD}\x{10000}-\x{10FFFF}]/u', '', $string);
+ }
}
"url": "http://git.syncroton.org/Syncroton"
}],
"require": {
- "tine20/composerapploader": "dev-master",
+ "zendframework/zendframework1": "1.12.18pl1 as 1.12.18",
+ "tine20/composerapploader": "1.0.*",
- "syncroton/syncroton": "1.1.*",
+ "syncroton/syncroton": "1.2.*",
"ezyang/htmlpurifier": "v4.6.0",
- "codeplex/phpexcel": "1.7.8",
- "phpoffice/phpword": "0.12.*",
+ "phpoffice/phpexcel": "1.8.*",
+ "phpoffice/phpword": "v0.13.*",
"sabre/dav": "1.8.*",
"sabre/vobject": "3.1.3 as 2.1.313",
"metaways/opendocument": "1.1",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
- "hash": "dff39568365f10df883d063e2fa3718f",
- "content-hash": "f97848576f56976d07b2e2a229ac3514",
- "hash": "9e806405c526ac27d9109817bedafc15",
- "content-hash": "73ab7c882ce6beb2ce883c4fd3acd5ff",
++ "hash": "54935eb2f908ae818bf78f3388dd8afc",
++ "content-hash": "e8faf6266f3919e23695d0621723279c",
"packages": [
{
- "name": "codeplex/phpexcel",
- "version": "1.7.8",
- "source": {
- "type": "git",
- "url": "https://github.com/markushausammann/PHPExcel.git",
- "reference": "6236b1e1513dda38a68a5ac22bbab5fc2b7942fd"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/markushausammann/PHPExcel/zipball/6236b1e1513dda38a68a5ac22bbab5fc2b7942fd",
- "reference": "6236b1e1513dda38a68a5ac22bbab5fc2b7942fd",
- "shasum": ""
- },
- "require": {
- "ext-xml": "*",
- "php": ">=5.2.0"
- },
- "type": "library",
- "autoload": {
- "psr-0": {
- "PHPExcel": ""
- }
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "LGPL"
- ],
- "authors": [
- {
- "name": "Maarten Balliauw",
- "homepage": "http://blog.maartenballiauw.be"
- },
- {
- "name": "Mark Baker"
- },
- {
- "name": "Erit Tilt"
- }
- ],
- "description": "PHPExcel - OpenXML - Create Excel2007 documents in PHP - Spreadsheet engine",
- "homepage": "http://phpexcel.codeplex.com",
- "keywords": [
- "OpenXML",
- "excel",
- "php",
- "spreadsheet"
- ],
- "abandoned": "phpoffice/phpexcel",
- "time": "2012-11-21 10:55:52"
- },
- {
"name": "doctrine/annotations",
"version": "v1.2.7",
"source": {