Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

italian set

I'm italian, and I use character as è à ò: ho can I add this set
@setlocale(LC_TIME, 'it_IT');
Thanks

Comments

  • and when customer post a reply into his ticket, after click on post reply-->show a blank page!
  • Posting replay on this incase others are looking for the answer!

    You should change the settings to use strftime..
    In class.format.php change the function to:

    function date($format,$gmtimestamp,$offset=0,$daylight=false){
    setlocale(LC_ALL, 'sv_SE');
    if(!$gmtimestamp || !is_numeric($gmtimestamp)) return "";
    $offset+=$daylight?date('I',$gmtimestamp):0; //Daylight savings crap.
    return strftime($format,($gmtimestamp+($offset*3600)));
    }

    Set locale to your own and then in settings change the date and time format to according for exempel (more info se php manual for strftime):

    Time Format: %k:%M
    Date Format: %Y/%m/%d
    Date & Time Format: %Y %m/%d %k:%M
    Day, Date & Time Format: %A %e %B %Y klockan %k:%M
  • TACK Claes!!

    I've been looking for this for ages.

    :D
  • Hi again,

    I'm having problems with å ä ö. (example Måndag)
    It shows as m�ndag.

    Do you know how to fix this? It appears on viewticket and I have the php pages in UTF-8.

    Thanks

    Robert
  • Sorry missed one thing..
    Use this..

    function date($format,$gmtimestamp,$offset=0,$daylight=false){

    setlocale(LC_ALL, 'sv_SE.UTF-8');

    if(!$gmtimestamp || !is_numeric($gmtimestamp)) return "";

    $offset+=$daylight?date('I',$gmtimestamp):0; //Daylight savings crap.
    return strftime($format,($gmtimestamp+($offset*3600)));
    }
  • Thank you so much, you're the man!
    Works like a charm.
Sign In or Register to comment.