So members register a timezone from a HTML select list (values -5, +6.5 and so on), and I am going to do a simple +/- in the timestamp on the page where it is.
Basically, this is what I came up with (with help from Google, my dear friend):
$timeone = "+10";
$timetwo = "-4";
$number = "18:00";
$exchange = substr($timetwo, 0, 1);
$therest = substr($timetwo, 1);
$result = $number. " " .$exchange. " " .$therest;
$add_em = explode("+", $result);
$add_em = explode("-", $result);
echo array_sum($add_em);
?>
Timeone works, but not timetwo. Could anyone try to help me?