I have a class in c# in that store some user messages, and return it as a string
the problem is when using hebrew character ,it return to the page as symbols.
I am using “remote scripting” by Brent Ashley, to update the server side ,so I get those
strings to the javascript using this method.
if I use the remote scripting to communicate with the server side, without calling the class methods,I can get strings just right,so I think it’s more like class encoding then remote scripting encoding.
Thanks
Honestly, I would suggest looking into alternatives at this point. If you are on at least .Net 3.0, you should be able to use an ASMX with methods marked as ScriptService and access these with jQuery, or another library that wraps AJAX calls in a friendly manner.
I would suggest avoiding the ScriptManager, as it and the rest of the Microsoft Ajax Toolkit tend to be problematic in the long run.
I can’t speak for how difficult it may be to refactor your codebase to support this, however.
That said… What you should consider doing is escaping the text with HtmlEncode, or UrlEncode, and see how the results work out. It may well be something to do with the transport encoding not defaulting to UTF-8 either in the main document, or in the remote script calls.