How to Change the Language

Last post 08-09-2009, 10:39 AM by cutechat. 4 replies.
Sort Posts: Previous Next
  •  01-21-2009, 3:19 AM 47915

    How to Change the Language

    Hello Adam.....I don't know how to change the language. I set the Language to zh-cn, but in somewhere,it's still display the english.
     
    example: Thanks for contacting us. Please hold a moment while we route your chat to a specialist who will help you with your question:
     
    How to delete this message or change to chinese? 
     
     
  •  01-22-2009, 3:56 PM 47985 in reply to 47915

    Re: How to Change the Language

    Open CuteSoft_Client\CuteChat\SupportClient.js and modify the following code:
     
    html="Thanks for contacting us. Please hold a moment while we route your chat to a specialist";

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  01-22-2009, 6:59 PM 47988 in reply to 47985

    Re: How to Change the Language

     
      Thanks Adam,I found [[Name]] ,[[Email]],[[Question]],[[Department]] in the SupportClient.aspx. how to customize them?
     
      I modified zh-cn.xml in the Language folder,but seem not to change.
     
      Thank you
  •  08-06-2009, 4:42 AM 54546 in reply to 47985

    Re: How to Change the Language

    Hello Adam,
     
    we have a multi lingual site, and based on the lanuage of the page where the live chat button sits on, I would like to start the live chat in english or in German.
     
    Is there a straightforward way to do this? I want to have the client UI in the proper language, as well as the automated messages which I guess come from the before-mentioned js file.
     
    Thanks for your inout in advance,
     
    Mikael
  •  08-09-2009, 10:39 AM 54587 in reply to 54546

    Re: How to Change the Language

    Mikael,
     
    You can hook the asp.net application event for that :
     
    (example ,put this method into the global.asax)
     
    protected void Application_PreRequestHandlerExecute(Object sender, EventArgs e)
    {
     if(Context.Request.RawUrl.ToLower().IndexOf("/cutechat/")==-1)return;
     if(Context.Session==null)return;
     object val=Context.Session["_lastCulture"];
     if(val==null)return;
     System.Globalization.CultureInfo culture=System.Globalization.CultureInfo.CreateSpecificCulture(val.ToString());
     System.Threading.Thread.CurrentThread.CurrentCulture=culture;
     System.Threading.Thread.CurrentThread.CurrentUICulture=culture;
     //throw(new Exception(val.ToString()));
    }
     
    Set the value in another page :
     
    private void ButtonCulture_Click(object sender, System.EventArgs e)
    {
       Session["_lastCulture"]=DDLCultures.SelectedValue;
    }
     
    This example need turn on Session state.
     
    Regards,
    Terry
View as RSS news feed in XML