What are the exact reasons for needing php 5.2?
Just "hacked" the check.php script, because I don't want to "mess up" my base CentOS 5.3 system which suns php 5.1.6. Of course I know I can use other repo's like remi, but that installs other things too, what I don't want to do at the moment.
I installed 0.3rc,and have been playing with it but as far I can see it runs fine on 5.1.6. But I don't know what happens under water.
all u have to do is "yum update php" in ssh to update it, i had no issues.
Well, that depends on which repo's you use.
And I stick to the base!
But that was nog my question, I want what specific things from 5.2 are needed/used.
Please ask developers at mailing list (RoundCube Mailing Lists (http://lists.roundcube.net/dev)).
Quote from: rosali;20475Please ask developers at mailing list (RoundCube Mailing Lists (http://lists.roundcube.net/dev)).
Thanks will do!
the roundcubemail 0.1.1 depot EPEL does not work
What used php ?
stable depot vs c5-testing depot ...... :)
mymail (
[email protected])
I'm running roundcube 0.3.1 on RHEL 5.4, this comes with a php 5.1.6 installation.
the only thing that's missing from that php version is the function json_encode.
somebody on php.net wrote a php implementation of this function, I added following code to program/include/rcube_shared.inc :
if (!function_exists('json_encode'))
{
function json_encode($a=false)
{
if (is_null($a)) return 'null';
if ($a === false) return 'false';
if ($a === true) return 'true';
if (is_scalar($a))
{
if (is_float($a))
{
// Always use "." for floats.
return floatval(str_replace(",", ".", strval($a)));
}
if (is_string($a))
{
static $jsonReplaces = array(array("\\", "/", "\n", "\t", "\r", "\b", "\f", '"'), array('\\\\', '\\/', '\\n', '\\t', '\\r', '\\b', '\\f', '\"'));
return '"' . str_replace($jsonReplaces[0], $jsonReplaces[1], $a) . '"';
}
else
return $a;
}
$isList = true;
for ($i = 0, reset($a); $i < count($a); $i++, next($a))
{
if (key($a) !== $i)
{
$isList = false;
break;
}
}
$result = array();
if ($isList)
{
foreach ($a as $v) $result[] = json_encode($v);
return '[' . join(',', $result) . ']';
}
else
{
foreach ($a as $k => $v) $result[] = json_encode($k).':'.json_encode($v);
return '{' . join(',', $result) . '}';
}
}
}
All that was left was changing the php version check in the installer installer/check.php :
from:
define('MIN_PHP_VERSION', '5.2.0');
to:
define('MIN_PHP_VERSION', '5.1.6');
And everything seems to work fine for me.
Just wanted to thank fretn for this post. I have rc running on my RHEL 5.5 server now.
Thanks again,
-Art
I am getting the following message in syslog:
roundcube: PHP Warning: setcookie() expects at most 6 parameters, 7
Some quick googling leads me to believe that a seventh parameter was added in PHP v 5.2 (httponly), after grepping through the code, I don't easily see how to adjust the parameters sent when creating the cookie. Has anyone experienced this issue to date?
Thanks,
-Art
I am running RoundCube version 0.4-beta.
just remove the last "true" from the parameters list
program/include/rcmail.php on line 1187:
//setcookie($name, $value, $exp, $cookie['path'], $cookie['domain'], rcube_https_check(), true);
setcookie($name, $value, $exp, $cookie['path'], $cookie['domain'], rcube_https_check());