[CLOSED] Turkish special characters problem

  1. #1

    [CLOSED] Turkish special characters problem

    Hi,

    If you set locale to tr (or just set Thread's culture), some special turkish characters appears wrong.


    1. Goto examples (v8) and open Locale demo
    2. Set language to Turkish.
    3. May corresponds to mayis, august corresponds to Agustos but it cannot dispaly special charakters ( i and g )


    If I put a reference to ext-lang-tr.js, everything works. I think we have a character encoding problem.


    -tansu
  2. #2

    RE: [CLOSED] Turkish special characters problem

    Hi,

    For me it shows as in file
    "Mayıs"
    "Ağustos"

    Under what browser do you have the problem? May be are there another conditions to reproduce the problem?
    Vladimir Shcheglov
    Sr. Developer
  3. #3

    RE: [CLOSED] Turkish special characters problem



    Hi Vlademir,

    You're right. I found the file in Coolite solution, it is incorrect in file.

    Below is the correct version. You can just paste it.



    
    /**
    * List compiled by mystix on the extjs.com forums.
    * Thank you Mystix!
    *
    * Turkish translation by Alper YAZGAN
    * 2008-01-24, 10:29 AM 
    * 
    * Updated to 2.2 by YargicX
    * 2008-10-05, 06:22 PM
    */
    
    
    Ext.UpdateManager.defaults.indicatorText = '<div class="loading-indicator">Yükleniyor ...
    ';
    
    
    if(Ext.View){
      Ext.View.prototype.emptyText = "";
    }
    
    
    if(Ext.grid.GridPanel){
      Ext.grid.GridPanel.prototype.ddText = "Seçili satir sayisi : {0}";
    }
    
    
    if(Ext.TabPanelItem){
      Ext.TabPanelItem.prototype.closeText = "Sekmeyi kapat";
    }
    
    
    if(Ext.form.Field){
      Ext.form.Field.prototype.invalidText = "Bu alandaki deger geçersiz";
    }
    
    
    if(Ext.LoadMask){
      Ext.LoadMask.prototype.msg = "Yükleniyor ...";
    }
    
    
    Date.monthNames = [
      "Ocak",
      "Subat",
      "Mart",
      "Nisan",
      "Mayis",
      "Haziran",
      "Temmuz",
      "Agustos",
      "Eylül",
      "Ekim",
      "Kasim",
      "Aralik"
    ];
    
    
    Date.getShortMonthName = function(month) {
      return Date.monthNames[month].substring(0, 3);
    };
    
    
    Date.monthNumbers = {
      Jan : 0,
      Feb : 1,
      Mar : 2,
      Apr : 3,
      May : 4,
      Jun : 5,
      Jul : 6,
      Aug : 7,
      Sep : 8,
      Oct : 9,
      Nov : 10,
      Dec : 11
    };
    
    
    Date.getMonthNumber = function(name) {
      return Date.monthNumbers[name.substring(0, 1).toUpperCase() + name.substring(1, 3).toLowerCase()];
    };
    
    
    Date.dayNames = [
      "Pazar",
      "Pazartesi",
      "Sali",
      "Çarsamba",
      "Persembe",
      "Cuma",
      "Cumartesi"
    ];
    
    
    Date.shortDayNames = [
      "Paz",
      "Pzt",
      "Sal",
      "Çrs",
      "Prs",
      "Cum",
      "Cmt"
    ];
    
    
    Date.getShortDayName = function(day) {
      return Date.shortDayNames[day];
    };
    
    
    if(Ext.MessageBox){
      Ext.MessageBox.buttonText = {
        ok     : "Tamam",
        cancel : "Iptal",
        yes    : "Evet",
        no     : "Hayir"
      };
    }
    
    
    if(Ext.util.Format){
      Ext.util.Format.date = function(v, format){
        if(!v) return "";
        if(!(v instanceof Date)) v = new Date(Date.parse(v));
        return v.dateFormat(format || "d/m/Y");
      };
    }
    
    
    if(Ext.DatePicker){
      Ext.apply(Ext.DatePicker.prototype, {
        todayText         : "Bugün",
        minText           : "Bu tarih izin verilen en küçük tarihten daha önce",
        maxText           : "Bu tarih izin verilen en büyük tarihten daha sonra",
        disabledDaysText  : "",
        disabledDatesText : "",
        monthNames        : Date.monthNames,
        dayNames          : Date.dayNames,
        nextText          : 'Gelecek Ay (Control+Right)',
        prevText          : 'Önceki Ay (Control+Left)',
        monthYearText     : 'Bir ay seçiniz (Yili artirmak/azaltmak için Control+Up/Down)',
        todayTip          : "{0} (Bosluk Tusu - Spacebar)",
        format            : "d/m/Y",
        okText            : "&amp;#160;Tamam&amp;#160;",
        cancelText        : "Iptal",
        startDay          : 1
      });
    }
    
    
    if(Ext.PagingToolbar){
      Ext.apply(Ext.PagingToolbar.prototype, {
        beforePageText : "Sayfa",
        afterPageText  : " / {0}",
        firstText      : "Ilk Sayfa",
        prevText       : "Önceki Sayfa",
        nextText       : "Sonraki Sayfa",
        lastText       : "Son Sayfa",
        refreshText    : "Yenile",
        displayMsg     : "Gösterilen {0} - {1} / {2}",
        emptyMsg       : 'Gösterilebilecek veri yok'
      });
    }
    
    
    if(Ext.form.TextField){
      Ext.apply(Ext.form.TextField.prototype, {
        minLengthText : "Girilen verinin uzunlugu en az {0} olabilir",
        maxLengthText : "Girilen verinin uzunlugu en fazla {0} olabilir",
        blankText     : "Bu alan bos birakilamaz",
        regexText     : "",
        emptyText     : null
      });
    }
    
    
    if(Ext.form.NumberField){
      Ext.apply(Ext.form.NumberField.prototype, {
        minText : "En az {0} girilebilir",
        maxText : "En çok {0} girilebilir",
        nanText : "{0} geçersiz bir sayidir"
      });
    }
    
    
    if(Ext.form.DateField){
      Ext.apply(Ext.form.DateField.prototype, {
        disabledDaysText  : "Disabled",
        disabledDatesText : "Disabled",
        minText           : "Bu tarih, {0} tarihinden daha sonra olmalidir", 
        maxText           : "Bu tarih, {0} tarihinden daha önce olmalidir",
        invalidText       : "{0} geçersiz bir tarihdir - tarih formati {1} seklinde olmalidir",
        format            : "d/m/Y",
        altFormats        : "d.m.y|d.m.Y|d/m/y|d-m-Y|d-m-y|d.m|d/m|d-m|dm|dmY|dmy|d|Y.m.d|Y-m-d|Y/m/d"
      });
    }
    
    
    if(Ext.form.ComboBox){
      Ext.apply(Ext.form.ComboBox.prototype, {
        loadingText       : "Yükleniyor ...",
        valueNotFoundText : undefined
      });
    }
    
    
    if(Ext.form.VTypes){
      Ext.apply(Ext.form.VTypes, {
        emailText    : 'Bu alan "user@domain.com" seklinde elektronik posta formatinda olmalidir',
        urlText      : 'Bu alan "http://www.domain.com" seklinde URL adres formatinda olmalidir',
        alphaText    : 'Bu alan sadece harf ve _ içermeli',
        alphanumText : 'Bu alan sadece harf, sayi ve _ içermeli'
      });
    }
    
    
    if(Ext.form.HtmlEditor){
      Ext.apply(Ext.form.HtmlEditor.prototype, {
        createLinkText : 'Lütfen bu baglanti için gerekli URL adresini giriniz:',
        buttonTips : {
          bold : {
            title: 'Kalin(Bold) (Ctrl+B)',
            text: 'Seçili yaziyi kalin yapar.',
            cls: 'x-html-editor-tip'
          },
          italic : {
            title: 'Italik(Italic) (Ctrl+I)',
            text: 'Seçili yaziyi italik yapar.',
            cls: 'x-html-editor-tip'
          },
          underline : {
            title: 'Alt Çizgi(Underline) (Ctrl+U)',
            text: 'Seçili yazinin altini çizer.',
            cls: 'x-html-editor-tip'
          },
          increasefontsize : {
            title: 'Fontu büyült',
            text: 'Yazi fontunu büyütür.',
            cls: 'x-html-editor-tip'
          },
          decreasefontsize : {
            title: 'Fontu küçült',
            text: 'Yazi fontunu küçültür.',
            cls: 'x-html-editor-tip'
          },
          backcolor : {
            title: 'Arka Plan Rengi',
            text: 'Seçili yazinin arka plan rengini degistir.',
            cls: 'x-html-editor-tip'
          },
          forecolor : {
            title: 'Yazi Rengi',
            text: 'Seçili yazinin rengini degistir.',
            cls: 'x-html-editor-tip'
          },
          justifyleft : {
            title: 'Sola Daya',
            text: 'Yaziyi sola daya.',
            cls: 'x-html-editor-tip'
          },
          justifycenter : {
            title: 'Ortala',
            text: 'Yaziyi editörde ortala.',
            cls: 'x-html-editor-tip'
          },
          justifyright : {
            title: 'Saga daya',
            text: 'Yaziyi saga daya.',
            cls: 'x-html-editor-tip'
          },
          insertunorderedlist : {
            title: 'Noktali Liste',
            text: 'Noktali listeye basla.',
            cls: 'x-html-editor-tip'
          },
          insertorderedlist : {
            title: 'Numarali Liste',
            text: 'Numarali lisyeye basla.',
            cls: 'x-html-editor-tip'
          },
          createlink : {
            title: 'Web Adresi(Hyperlink)',
            text: 'Seçili yaziyi web adresi(hyperlink) yap.',
            cls: 'x-html-editor-tip'
          },
          sourceedit : {
            title: 'Kaynak kodu Düzenleme',
            text: 'Kaynak kodu düzenleme moduna geç.',
            cls: 'x-html-editor-tip'
          }
        }
      });
    }
    
    
    if(Ext.grid.GridView){
      Ext.apply(Ext.grid.GridView.prototype, {
        sortAscText  : "Artan sirada sirala",
        sortDescText : "Azalan sirada sirala",
        lockText     : "Kolonu kilitle",
        unlockText   : "Kolon kilidini kaldir",
        columnsText  : "Kolonlar"
      });
    }
    
    
    if(Ext.grid.GroupingView){
      Ext.apply(Ext.grid.GroupingView.prototype, {
        emptyGroupText : '(Yok)',
        groupByText    : 'Bu Alana Göre Grupla',
        showGroupsText : 'Gruplar Halinde Göster'
      });
    }
    
    
    if(Ext.grid.PropertyColumnModel){
      Ext.apply(Ext.grid.PropertyColumnModel.prototype, {
        nameText   : "Ad",
        valueText  : "Deger",
        dateFormat : "d/m/Y"
      });
    }
    
    
    if(Ext.layout.BorderLayout &amp;&amp; Ext.layout.BorderLayout.SplitRegion){
      Ext.apply(Ext.layout.BorderLayout.SplitRegion.prototype, {
        splitTip            : "Yeniden boyutlandirmak için sürükle.",
        collapsibleSplitTip : "Yeniden boyutlandirmak için sürükle. Saklamak için çift tikla."
      });
    }
  4. #4

    RE: [CLOSED] Turkish special characters problem

    Problem is, original language file does not have UTF-8 encoding. It is also incorrect in official extjs distribution and special Turkish characters displays wrong.

    -tansu
  5. #5

    RE: [CLOSED] Turkish special characters problem

    Hi,

    Thanks for the information. We will use your version of translation
    Vladimir Shcheglov
    Sr. Developer
  6. #6

    RE: [CLOSED] Turkish special characters problem

    Thanks.
  7. #7

    RE: [CLOSED] Turkish special characters problem

    Hi,

    We have fixed it. Thanks again
    Vladimir Shcheglov
    Sr. Developer

Similar Threads

  1. [CLOSED] Special characters dosen't works in message box in IE8
    By Daly_AF in forum 2.x Legacy Premium Help
    Replies: 2
    Last Post: Aug 03, 2012, 12:01 PM
  2. [CLOSED] ColumnName with Special Characters in GridPanel
    By UnifyEducation in forum 2.x Legacy Premium Help
    Replies: 1
    Last Post: Jun 07, 2012, 7:12 PM
  3. Turkish Character Problem
    By mikser in forum 2.x Help
    Replies: 0
    Last Post: May 04, 2012, 12:30 PM
  4. [CLOSED] Special char problem
    By majestic in forum 1.x Legacy Premium Help
    Replies: 7
    Last Post: Jul 26, 2010, 11:32 AM
  5. Replies: 0
    Last Post: Jun 11, 2010, 2:04 AM

Posting Permissions