#381 localization: add "strtotime" function to xoopslocal class

XOOPS_2.6
open
nobody
Core (214)
7
2014-08-14
2012-06-23
irmtfan
No

Now local parties that uses non Gregorian calendars like hegira calendar must HACK all core/modules that uses this php function like newbb/polls.php xoopspoll and ...
Please add this function to class/xoopslocal.php like below:

[code]
class XoopsLocalAbstract
{
/**

function strtotime($datestr)
{
    /* here return the datestr to datenum */
}

[/code]

Discussion

  • irmtfan
    irmtfan
    2012-06-23

    I just find this code in joomla:

    function date_strtotime($date)
    {
    $strtotime = strtotime($date);
    if ($strtotime === -1 || $strtotime === false)
    {
    return false;
    }
    else
    {
    return $strtotime;
    }
    }

    Im not a coder. what is your idea as a developer?