taskman_i18n/i18n.inc.php

17 lines
390 B
PHP
Raw Normal View History

2022-05-18 09:49:49 +03:00
<?php
namespace taskman;
function i18n_decode_string($str)
{
return preg_replace(array("/\\\\\"/", "/\\\\r/", "/\\\\n/", "/\\\\t/"), array("\"", "\r", "\n", "\t"), $str);
}
function i18n_encode_string($str)
{
$str = str_replace("\n", '\n', $str);
$str = str_replace("\r", '\r', $str);
$str = str_replace("\t", '\t', $str);
$str = str_replace("\"", '\"', $str);
return $str;
}