11 Replies Latest reply on Dec 4, 2009 2:50 AM by BKBK

    GetProfileString doesn't support unicode format.??

    pyae phyoe shein Level 1

      <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">


          <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />


      <cfset currentPath = getCurrentTemplatePath()>
      <cfset currentDirectory = getDirectoryFromPath(currentPath)>




      function udf_Translate(Name, Filename, Section) {
          var outText="";


          //    If user selected default language (English), bypass the translation
          if (cookie.cookie_language eq "EN")
              return Name;
          if (Filename eq "")
              Filename = "Common";
          if (Section eq "")
              Section = "Common";
          INI_Path = #currentDirectory# & "Language.properties";
          outText = GetProfileString(INI_Path, Section, Name);
        return IIf(Len(Trim(outText)) gt 0, DE(outText), DE(Name));


      <cfoutput>#udf_translate("Ward", "Inpatient", "")#</cfoutput>










      It output only "Ward" instead of Phường when I save this file as UFT-8. But, when I save this file as ANSI encoding, it output as Phu?ng. It's wrong. Why GetProfileString doesn't UTF-8 format? Any solutions will be appreciated.